Next add a line / lines Debugger.Break(); in your code where you want the debugger to start. Now compile in debug mode clicking in Visual Studio menu: Build, Build Solution while the Configuration Manager is set to Debug.
After the application compiled successfully we can stop and start the service to ensure these modifications are run:
Right click the Visual Studio application and select more…, Run as administrator
Click Debug, Attach to Process in the Visual Studio menu.
This will open a dialog where you need to select the right process to debug. Check the Show processes from all users checkbox. Find your Service process and click Attach.