Link to home
Start Free TrialLog in
Avatar of mmilan
mmilan

asked on

Working in background

How can I make program that work in background? I want to make program that save the time when Windows is starting, write it on the screen, and after that, in evry moment, write curent time and distance between that two times?
How to do this?
Avatar of Matvey
Matvey

For your program to work in background you can make just a normal program that gets the time every second, makes the calculations you want etc. The only thing your program will need is to be unvisible in the taskbar and start when windows starts.

You can use this component to make it start when windows starts:
http://bes.trendline.co.il/torry/vcl/system/amarun.zip

And you can use these components to hide the button on taskbar:
http://bes.trendline.co.il/torry/vcl/system/appvisib.zip
http://bes.trendline.co.il/torry/vcl/system/thidetask.zip
http://bes.trendline.co.il/torry/vcl/system/notask.zip
mmilan

when you say write it on the screen you mean the desktop or a form you've created...

Later
BoRiS
Ahh, forgot to mention. When your program starts, get the time by calling Then := Now. Then every second calculate Differ := Now-Then, and display it using TimeTostr(Differ)...

From Boris'es comment - maybe it's a good idea to use Screen.Canvas.TextOut(TimeToStr(Differ)) (??not sure it'll work, but a good idea)
ASKER CERTIFIED SOLUTION
Avatar of ShadowHawk071998
ShadowHawk071998

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial