Page 1 of 1

Time of day

Posted: Fri Dec 02, 2011 2:41 pm
by mathias
Is it possible to show the actual time of day (time of the PC) in a label? I tried to use “GetTimeString(":")” but i don’t find a solution.

Thanks

Re: Time of day

Posted: Mon Dec 05, 2011 8:07 am
by admin
Hi,
yes, it is possible.
- Create a string gate with your desired name such as "DateTime".

- Enter in the Winlog code this function:

Code: Select all

Function void DateTime()
#startup
While(WindowIsOpen())
SetStrGateValue("DateTime", 0, GetTimeString(":"));
Sleep(1000);
end
end
- Attach the gate to the label in the template.