[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 255
  • Last Modified:

How to terminate the application

Dear all

If the application is ideal  for some time
i want to shut down the application automatically?

Thanx in advance
0
ravisiva
Asked:
ravisiva
1 Solution
 
DragonSlayerCommented:
do checking at the Application.OnIdle?
0
 
shaneholmesCommented:
Application.Terminate

Shane
0
 
cruxyCommented:
Use a timer with, say 30 sec's. Retrigger it on each Application.OnIdle Event (nothing has been done since then) - but only if no timer message arrived - Call Application.terminate after the timer raised 5 times...

An other solution would be to trap all mouse/keyboard messages with an Application.OnMessage Handler and retrigger a timeout with that.
0
 
HypoviaxCommented:
Yep, like Shane says:

Application.Terminate
0
 
HypoviaxCommented:
Well the correct answer here is Shane's comment although if you would like to give me some points i would be happy ;-)

Hypoviax
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now