Sign in to follow this  
Followers 0
blender

Is there a function in autoIt to obtain the current time?

3 posts in this topic

As the title says, Is there a function in autoIt to obtain the current time? I tried TimerInit() but it doesn't give me the actual time.

Another question I have here is that I want to compare to strings. I want to check if string A contains string B. Is it possible to do it in autoIt?

Thank you in advance!

Share this post


Link to post
Share on other sites



#include <GUIConstants.au3>

HotKeySet("{ESC}", "_Exit")
$GUI = GUICreate("Time", 150, 100, -1, -1)
$Time = GUICtrlCreateLabel(@HOUR & ":" & @MIN & ":" & @SEC, 10, 25, 150, 100)
GUICtrlSetFont($Time, 25)
GUISetState(@SW_SHOW)

While 1
    $nMsg = GUIGetMsg()
    Select
    Case $nMsg = $GUI_EVENT_CLOSE
        ExitLoop
    EndSelect
    GUICtrlSetData($Time, @HOUR & ":" & @MIN & ":" & @SEC)
WEnd

Func _Exit()
    Sleep(500)
    Exit
EndFunc


Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Share this post


Link to post
Share on other sites

#include <Date.au3>

$time = _NowCalc()

MsgBox( 4096, "Time", $time)

If you don't want the date you can just modify it.

Share this post


Link to post
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
Sign in to follow this  
Followers 0