In window service onstart method, i have written a code to fetch data from a table which is located on server,
when i start the service it gives the service1 service on local computer started and stopped. Some services stop automatically if they have no work to do.
but when i use connection string of my pc i mean database on my pc it work properly.
Any Idea!
Loading

Vijay YadavPosted May 2, 2011, 4:01 AM
The problem gor resolved, there was a problem in connectionstring.
Vijay YadavPosted May 2, 2011, 2:39 AM
Vijay YadavPosted Apr 30, 2011, 9:56 AM
Thanks for your reply but its working fine on my PC and in LAN as well but not on web server,
though i have set the account to network service but still not working.
Any idea regarding this?
Soft CornerPosted Apr 30, 2011, 9:53 AM
1. You can not return any value from windows service
2. I had the same problem for a long time and finally find the solution that is to clear the Application Log. It might help you to resolve this problem as well.