I have a winform application (.exe file) in my windows server 2008 VPS.
This app should grab some data from internet every 5 minutes and save them to a text file.
My VPS restarts after 2 or 3 days for no reason.
I want to force my server run that application on startup & execute it in every reboot.
For this purpose i followed this instruction :
It is simple. The process is.
- Run gpedit.msc
- Go to computer Configuration -> Windows Setting -> Scripts(Startup/shutdown)
- Go to Startup properties then you will get the new windows.
- Now add the program that you want to run before login.
The problem is that file is executed on startup, but after login to windows i can not see it's form is running.
I can see that app is running in task manager.
How can i see that winform after login to windows?(I need GUI)
I mean my application must be running even before log in and it should sit on System Tray from which I can "show" Interface for interact.
If there is a way in c# programming for show that app after login please share.