I want to make a Windows service that will access my database. My database is SQL Server 2005.
Actually I am working on a website and my database is inside our server. I need to access my database every second and update the records. For that purpose I need to make a Windows service that will install into our server and perform the task.
I have been accessing the database from my local machine and then running the service, but problem is I’m not sure how I can test this service.
I tried to install into my local machine. It installed and then I ran the service but it did not perform the task and I think service is not able to connect with the database.
There is no problem in the service nor its installer. The only issue is how to test my Windows service.
You can attach the visual studio solution to the windows service application. Then you can debug the windows service as you do a normal project.
Debug –> Attach to process.