Jump to content

Newb project suggestions


ZeRo2157
 Share

Recommended Posts

Hey! I'm thinking of making my first actual program using AutoIt. I was thinking of a program that would be somewhat like those alarm clock things that at a given time would perform specified actions etc.

So far this is what I have. When executed, the user can specify a time (ex 6.AM), once the system clock time matches the user specified time then the program would start to go about its chores. Here is a list of what I hope it will do when its complete:

-Wait until the specified time matches the system time

-Open Windows Media Player and play the current playlist

-Open Internet Explorer and go to CNN.com and minimize the window

-Open another IE window but rather go to a specified page

-Terminate the program

I'd love it if you guys wanted to suggest anything else this thing could do!

So far I only have one quick question, but no doubt there will be more o:)

Is there a command in AutoIt that returns the value of the system time? Like, uhmmm....Time$ in QBASIC would return "1:38 AM" for example if the current system time was of course 1:38AM

Thanks for any help! :lmao:

*Note* - I'd appreciate it if you would just explain the concepts to me rather than just throw chunks of code at me, I'm still tryin to learn ya know!

Link to comment
Share on other sites

;Compare date

If @MDAY = "13" AND @MON = "05" Then
  ;Compare time
   If @HOUR = "01" AND @MIN = "38" Then
     ;It's time!
   EndIf
EndIf

It's not that difficult. I made one myself.

Two weeks spent on it and I was satisfied.

- You should write/type everything you want to do.

- Then you organize everything and create steps.

* Step 1 - Show clock

* Step 2 - Update clock once in a while

* Step 3 - Check date and time

* etc..

Edited by SlimShady
Link to comment
Share on other sites

;Compare date

If @MDAY = "13" AND @MON = "05" Then
 ;Compare time
   If @HOUR = "01" AND @MIN = "38" Then
    ;It's time!
   EndIf
EndIf

It's not that difficult. I made one myself.

Two weeks spent on it and I was satisfied.

- You should write/type everything you want to do.

- Then you organize everything and create steps.

  * Step 1 - Show clock

  * Step 2 - Update clock once in a while

  * Step 3 - Check date and time

  * etc..

<{POST_SNAPBACK}>

I prefer to make psuedocode steps, loops, dialgouges and such...

#includes

Dim $variables

PrimaryGUI()

While 1; primary data loop
   Sleep(10)
   $msg = GUIGetMsg()
   Select 
      Case $msg = $GUI_Event_Close or $msg = $cancel
         ExitLoop
      Case $msg = Run button
          Run Loop
          End of run functions
      Case $msg = Config button
           Create ConfigGUI()
           Config Loop
           Recall Primary GUI()
      Case Button Other
          ; Do something else
    EndSelect
WEnd
;Do some quit functions.  File cleanup, etc.
Exit

Func PrimaryGUI()
; draw primary GUI
EndFunc

Func ConfigGUI()
; draw configuration GUI
EndFunc

Then I'll replace the psuedo code with actual code as I go along.

It helps to have a basic structure to go off of. But whatever works. Flowcharting is the same idea, just different symbology. I always HATED drawing those damn things up in school.... However you organize your data is just fine. There's no grades here, just pass (program runs) or fail (program breaks).

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...