inno setup 安装 .net 服务
2012-05-19 10:23
183 查看
inno setup 脚本
installService.bat
unstallService.bat
已在xp,win7下测试通过。
ikmb@163.com
#define MyAppName "getService" #define MyAppVersion "1.0" #define MyAppPublisher "AZ Studio" #define MyAppURL "http://sou.niceant.com" #define MyAppExeName "getService.exe" [Setup] ; 注: AppId的值为单独标识该应用程序。 ; 不要为其他安装程序使用相同的AppId值。 ; (生成新的GUID,点击 工具|在IDE中生成GUID。) AppId={{4138D01D-3AC5-4180-9E7E-96FEB59CE393} AppName={#MyAppName} AppVersion={#MyAppVersion} ;AppVerName={#MyAppName} {#MyAppVersion} AppPublisher={#MyAppPublisher} AppPublisherURL={#MyAppURL} AppSupportURL={#MyAppURL} AppUpdatesURL={#MyAppURL} DefaultDirName={pf}\{#MyAppName} DefaultGroupName={#MyAppName} LicenseFile=E:\iDev\getBT\getBT\setup\publish\innosetup\program\license.txt OutputBaseFilename=setup Compression=lzma SolidCompression=yes [Languages] Name: "chinesesimp"; MessagesFile: "compiler:Default.isl" [Files] ;Source: "E:\iDev\getBT\getBT\setup\publish\innosetup\program\getService.exe"; DestDir: "{app}"; Flags: ignoreversion Source: "E:\iDev\getBT\getBT\setup\publish\innosetup\program\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs ; 注意: 不要在任何共享系统文件上使用“Flags: ignoreversion” [Icons] Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" [Run] Filename: "{app}\installService.bat"; Description: "注册服务";Flags:runhidden [UninstallRun] Filename: "{app}\unstallService.bat";Flags:runhidden
installService.bat
sc create "getService" binPath= "%~dp0getService.exe" start= auto net start "getService"
unstallService.bat
net stop "getService" sc delete "getService"
已在xp,win7下测试通过。
ikmb@163.com
相关文章推荐
- 使用.NET 创建Windows系统服务及安装完全教程
- .NET 1.1安装不了提示安装程序初始化时出错或提示windows intall服务不可用
- .NET : 自定义安装服务
- C#创建服务及使用程序自动安装服务,.NET创建一个即是可执行程序又是Windows服务的exe
- .net安装windows服务和生产webservice
- .net Windows服务程序和安装程序制作
- Inno Setup 制作安装程序[支持静默安装.NET环境]
- .Net实现Windows服务安装完成后自动启动的两种方法
- 关于.net下服务安装
- Inno Setup 制作安装程序[支持静默安装.NET环境]
- 在.net中安装服务
- 使用.NET创建Windows系统服务及安装完全教程(收藏)
- IIS与.NET顺序安装反了,无法建ASP.NET应用程序或者服务(Visual Studio.net 已检测到指定的WEB服务器运行的不是ASP。NET1.1版。)
- .net windows 服务创建、安装、卸载和调试
- C#创建服务及使用程序自动安装服务,.NET创建一个即是可执行程序又是Windows服务的exe(转)
- .Net开发的windows服务的安装
- 关于.net下服务安装
- .NET 创建Windows服务,及服务的安装卸载
- .net服务安装
- C#创建服务及使用程序自动安装服务,.NET创建一个即是可执行程序又是Windows服务的exe