[reply]set name=test
set path=D:\test\test.bat
net stop %name%
sc delete %name%
sc create %name% binPath=%path% DisplayName=%name%_service
sc config %name% start=AUTO
net start %name%
@ECHO if you want to stop: net stop %name%
@ECHO if you want to delete: sc delete %name%
[/reply]
set name=test
set path=D:\test\test.bat
net stop %name%
sc delete %name%
sc create %name% binPath=%path% DisplayName=%name%_service
sc config %name% start=AUTO
net start %name%
@ECHO if you want to stop: net stop %name%
@ECHO if you want to delete: sc delete %name%