Click here to Skip to main content
16,021,181 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
Am writing a file management dialog application to search delete and back up certain logfiles on a machine. Am using MFC in Microsoft Visual studio 2005 running on Windows xp. i would like to implement functionality such that there is an auto process running in the back ground such that at the end of every configurable period of time, the delete or backup process is initialised. this means that every time the machine shuts down or restarts, the process should continue from where it stopped. the process should also continue running even when the dialog that initialised it is closed. am finding a hard time to implement this functionality, please help.

Gerald
Posted

You need either to convert your application to a windows service that runs all the time and periodically goes through its housekeeping tasks, or add the application to the task scheduler to be run at some regular interval.
 
Share this answer
 
Thanks Richard for your help;
i will then emback on the option of using the task scheduler because i have so much layed out the outline of the application. What remains unclear for me however is how i can let the task sheduler perform a worker thread resume in the application. will it succeed while the dialog window is not active?
 
Share this answer
 
Comments
[no name] 7-Sep-10 12:22pm    
Task scheduler runs an application from start so you should not have a dialog box in it; the same applies to a service. As to starting from the position it last stopped at, that is the responsibility of the application to save and restore enough information to restart at the resume point.
Sandeep Mewara 7-Sep-10 13:40pm    
Reason for my vote of 1
Not an answer. Should have been a comment to the answer. That would had even notified the answerer that you were trying to reach him.
Ketan D Kulkarni 8-Sep-10 2:45am    
Reason for my vote of 1
ertg

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900