How to add a exe application run as a service(如何将一个可执行程序当作服务运行)?
2007-11-21 17:54
916 查看
Need two tools:instsrv.exe and srvany.exe
1. Download it from the following link:
http://mooncat.51.net/ls/fu/srvinstw.rar
http://fgg.minidns.net/scripts/lb5000/attachment.cgi?forum=32&topic=116&postno=1&type=.zip
2. Run the following command in dos window to install a service
[path of instsrv.exe] [service name] [path of srvany.exe]
3. Write a .reg file to load some values to registry. Following is a sample in the .reg file.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/service name/Parameters]
"Application"="c://usr//local//bin//dmh_wish.exe"
"AppParameters"="-f dmh84_server startup "
"AppDirectory"="c://usr//local//bin"
4. Run the following command in dos window to remove a service.
[path of instsrv.exe] "[service name]" remove
1. Download it from the following link:
http://mooncat.51.net/ls/fu/srvinstw.rar
http://fgg.minidns.net/scripts/lb5000/attachment.cgi?forum=32&topic=116&postno=1&type=.zip
2. Run the following command in dos window to install a service
[path of instsrv.exe] [service name] [path of srvany.exe]
3. Write a .reg file to load some values to registry. Following is a sample in the .reg file.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/service name/Parameters]
"Application"="c://usr//local//bin//dmh_wish.exe"
"AppParameters"="-f dmh84_server startup "
"AppDirectory"="c://usr//local//bin"
4. Run the following command in dos window to remove a service.
[path of instsrv.exe] "[service name]" remove
相关文章推荐
- 如何查看一个运行的exe执行程序需要有哪些DLL动态链接库
- 如何让一个程序作为服务运行
- 如何实现点击Winform程序窗体中的一个按钮,执行这个exe文件?
- How to run WPF - XBAP as Full Trust Application(如何运行WPF -作为完全信任的应用XBAP)
- 技巧(5)- 如何让这个程序在系统里同时只运行一个(如果这个exe程序已经运行了,就不再运行)
- C#如何编写程序运行exe可执行文件
- 如何把一个现成的exe文件合并到合并到我的程序里?运行时再释放出来?
- 如何把一个java程序打包成exe文件,运行在没有java虚
- C#创建服务及使用程序自动安装服务,.NET创建一个即是可执行程序又是Windows服务的exe(转)
- 创建一个既可作为普通exe(双击能运行),又可作为服务运行的程序
- 创建一个既可作为普通exe(双击能运行),又可作为服务运行的程序。
- 如何把一个java程序打包成exe文件,运行在没有java环境里
- C#创建服务及使用程序自动安装服务,.NET创建一个即是可执行程序又是Windows服务的exe
- Run As Service - 把任何可执行文件(包括批处理和角本)当作系统服务运行的工具(转)
- C#创建服务及使用程序自动安装服务,.NET创建一个即是可执行程序又是Windows服务的exe
- 用eclipse如何将java程序生成一个.exe可运行文件?
- 通过分析exevc系统调用处理过程来理解Linux内核如何装载和启动一个可执行程序
- 用myeclipse如何将java程序生成一个.exe可运行文件?
- windows 上一个.exe程序是如何运行的
- 用myeclipse如何将java程序生成一个.exe可运行文件?