Click here to Skip to main content
15,942,159 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
hi i want run windows application with windows service.
i have a windows service,this service should run windows application every 1 minute.
How to do it?
any solution can solve this problem,
thanks.
Posted
Comments
Jameel VM 12-Mar-13 4:43am    
I think you can run your windows app using Windows Task Scheduler.
Try this link
http://kodethoughts.blogspot.in/2009/06/creating-windows-task-scheduler-service.html

In your windows service set a timer loop with a tick of 1 minute and in the tick event use shellexecute to launch your windows apps .exe file.
 
Share this answer
 
Comments
mohsen_3325 12-Mar-13 5:42am    
i use this:'ProcessStartInfo info = new ProcessStartInfo(@"c:\myprogram.exe"); info.UseShellExecute = false; info.RedirectStandardError = true; info.RedirectStandardInput = true; info.RedirectStandardOutput = true; info.CreateNoWindow = true; info.ErrorDialog = false; info.WindowStyle = ProcessWindowStyle.Normal; Process process = Process.Start(info);'but can't show and not work.
mohsen_3325 12-Mar-13 5:43am    
no problem with timer,my problem :not show windows app
please help me.i can't solve this problem
 
Share this answer
 

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