Easier way to debug a Windows service

后端 未结 28 1582
春和景丽
春和景丽 2020-11-22 15:36

Is there an easier way to step through the code than to start the service through the Windows Service Control Manager and then attaching the debugger to the thread? It\'s ki

28条回答
  •  北海茫月
    2020-11-22 16:15

    You can also start the service through the command prompt (sc.exe).

    Personally, I'd run the code as a stand-alone program in the debugging phase, and when most bugs are ironed out, change to running as service.

提交回复
热议问题