Jump to content

Newbie Q - How to retrieve and use PC System Time?


Recommended Posts

Hello, hoping someone can point me in the right direction.

I've just started to learn AutoIt, and went through the documentation and tutorials. But I don't see a way to retrieve the PC's system time. I know I can get file creation times and what not, but how do I just get system time?

What I basically want to do is launch an app, then at specific times (say 9am and 9pm) I want to automatically click on some windows and enter some data.

The part I am stuck on is retrieving System Time from the PC and using that to mark the start of an action. Any help much appreciated.

Link to comment
Share on other sites

Thanks a bunch!

I did do some searchs, but obviously I didn't search extensively enough. Will do better next time.

Before you go posting on the forums: search the helpfile, search google, search forums. I just copied that code from searching 2mins, didnt even enter autoit. Otherwise good luck :)

$Time = @HOUR & ":" & @MIN & ":" & @SEC
$Date = @MON & "/" & @MDAY & "/" & @YEAR 
MsgBox(0, "", $Time & "  " & $Date)

Link to comment
Share on other sites

... What I basically want to do is launch an app, then at specific times (say 9am and 9pm) I want to automatically click on some windows and enter some data. ...

Welcome to the forum.

You might want to just use the operating system's Task Scheduler to handle launching things at certain times.

Edited by herewasplato

[size="1"][font="Arial"].[u].[/u][/font][/size]

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...