A Windows service is a computer program that operates in the background. It is similar in concept to a Unix daemon.


Most easy way is to use NSSM, the Non-Sucking Service Manager (created by Iain Patterson)


See Xml\Tutorial\5001 Advanced topics\0501 Run as a Windows service\ConvertCSV_Service.xml for the file used in this tutorial

1. Go to NSSM

Open a command prompt as Administrator



Go to the executable folder (in this example D:\Bin\Nssm\nssm-2.24\win64)




2. Install the service


Enter: nssm install csv2excel



The NSSM installer GUI appears



Set [Path] to D:\bin\Debug\VSConsole.exe


Set [Startup directory] to D:\bin\Debug


Set [Arguments] to "D:\Xml\Tutorial\5001 Advanced topics\0501 Run as a Windows service\ConvertCSV_Service.xml" True True



NSSM shows a window to notify the user that the services has been installed.




3. Check the status of the service

Enter: nssm status csv2excel




4. Start and stop the service

To start the service, type: nssm start csv2excel



To stop the service, type: nssm stop csv2excel




5. Remove the service

Type: nssm remove csv2excel



Nssm shows a confirmation window

Click [Yes] to confirm



Nssm shows a window to notify the user that the service has been removed (uninstalled)



End result on the command prompt






When running a ScriptoMate document as a Windows Service, make sure to design a loop in your processing. In the example that is achieved by the [Misc.RepeatInterval] action. A Windows Service in continuously active.