Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Working in background

Posted on 1998-07-23
4
166 Views
Last Modified: 2010-04-04
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?
0
Comment
Question by:mmilan
  • 2
4 Comments
 
LVL 3

Expert Comment

by:Matvey
ID: 1358580
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
0
 
LVL 4

Expert Comment

by:BoRiS
ID: 1358581
mmilan

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

Later
BoRiS
0
 
LVL 3

Expert Comment

by:Matvey
ID: 1358582
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)
0
 

Accepted Solution

by:
ShadowHawk071998 earned 10 total points
ID: 1358583
You also need to use the Timer of course.This is the component that allows you to 'go to
sleep' and only wake at certain 'intervals' (Like 1 second. EVery second is 1000 in the interval property). It's dead simple to use, it has one event (WHen the timer finished counting back).
good luck...
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question