Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
cpas6-install
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李金钢
cpas6-install
Commits
def72844
Commit
def72844
authored
Apr 01, 2026
by
Auto Backup
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: buildgb2312
parent
e169247e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
102 additions
and
102 deletions
+102
-102
CPAS6Setup_IASWithBom.iss
CPAS6Setup_IASWithBom.iss
+102
-102
No files found.
CPAS6Setup_IASWithBom.iss
View file @
def72844
; 脚本由 Inno Setup 脚本向导 生成!
;
有关创建 Inno Setup 脚本文件的详细资料请查阅帮助文档!
; 脚本由 Inno Setup 脚
本向导 生成!
;
有关创建 Inno Setup 脚本文
件的详细资料请查阅帮助文档!
#include AddBackslash( CompilerPath ) + "ISPPBUILTINS.ISS"
#define MyAppName "IAS
审计作业系统
"
; MyAppRegName
名称应保持与Config.ini中APPRegName配置一致,否则注册表读写不对应。
#define MyAppName "IAS
审计作
业系统"
; MyAppRegName
名称应保持与Config.ini中APPRegNam
e配置一致,否则注册表读写不对应。
#define MyAppRegName4 "UFCPAS4"
#define MyAppExeName4 "UFCPAS4.exe"
#define MyAppRegName6 "CPAS6"
...
...
@@ -12,7 +12,7 @@
;#define MyPMAppExeName "cpas-WorkPlatform.exe"
;#define MyPMAppEnName "cpas-WorkPlatform"
#define MyAppVersion "6.0.250909"
#define MyAppPublisher "
北京友数聚科技有限公司
"
#define MyAppPublisher "
北京友数
聚科技有限公司"
#define MyAppURL "http://www.youdatasum.com/"
#define SQL_Path "C:\AudSQL2014"
#define SQL_INSTANCE "MSSQL$AudSQL2014"
...
...
@@ -20,11 +20,11 @@
#define CurDateString GetDateTimeString('yyMMdd', '-', ':');
[Setup]
;
告知编译器使用 Unicode 模式处理字符
;
告知编译器使用 Unicod
e 模式处理字符
;
注: AppId的值为单独标识该应用程序。
;
不要为其他安装程序使用相同的AppId值。
; (
生成新的GUID,点击 工具|在IDE中生成GUID。
)
;
注: AppId的值为单独
标识该应用程序。
;
不要为其他安装程序使用
相同的AppId值。
; (
生成新的GUID,点击 工具
|在IDE中生成GUID。)
AppId={{UFAUD001-6EBAF16B-1F26-4ED9-B287-0F1010CFCCE2}
AppName={#MyAppName}
AppVersion=6.0.{#CurDateString}
...
...
@@ -35,9 +35,9 @@ DefaultDirName={code:GetDefaultDir}
DefaultGroupName={#MyAppName}
CreateAppDir=true
OutputBaseFilename={#MyAppName}Setup-{#CurDateString}
;lzma
压缩方式
lzma2/fast none
;lzma
压缩
方式 lzma2/fast none
compression=lzma
;
是否使用原来的安装路径,不让选择
;
是否使用原来的安
装路径,不让选择
UsePreviousAppDir=no
SolidCompression=yes
OutputDir=.
...
...
@@ -51,7 +51,7 @@ PrivilegesRequired=admin
SetupLogging=yes
[Files]
;6.0
项目管理工具与审计作业平台未分成两个EXE;
;6.0
项目管理工具与审计
作业平台未分成两个EXE;
Source: "{#MyAppExeName6}"; DestDir: "{app}"; Flags: ignoreversion;
Source: "{#MyAppExeName4}"; DestDir: "{app}"; Flags: ignoreversion;
Source: "AutoUpdate\update.inf"; DestDir: "{app}\AutoUpdate";
...
...
@@ -69,7 +69,7 @@ Source: "ssleay32.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "CPASProtocol.exe"; DestDir: "{app}"; Flags: ignoreversion;
Source: "borlndmm.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "UFCPASSetupDll.dll"; DestDir: "{app}\"; Flags: ignoreversion dontcopy
Source: "
重启资源管理器
.bat"; DestDir: "{app}"; Flags: ignoreversion
Source: "
重
启资源管理器.bat"; DestDir: "{app}"; Flags: ignoreversion
Source: "AppBPL\*"; DestDir: "{app}\AppBPL"; Flags: ignoreversion recursesubdirs createallsubdirs ;
Source: "Config\Config.ini"; DestDir: "{app}\Config"; Flags: ignoreversion
Source: "Config\Config.xml"; DestDir: "{app}\Config"; Flags: ignoreversion
...
...
@@ -81,32 +81,32 @@ Source: "Config\Symbol.ini"; DestDir: "{app}\Config"; Flags: ignoreversio
Source: "SysBPL\*"; DestDir: "{app}\SysBPL"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "Tools\*"; DestDir: "{app}\Tools"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "SourceData\*"; DestDir: "{app}\SourceData"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "
数据采集工具\*"; DestDir: "{app}\数据采集工具
"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "
演示数据\*"; DestDir: "{app}\演示数据
"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "
数据采集工具\*"; DestDir: "{app
}\数据采集工具"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "
演示数据\*"; DestDir: "{app
}\演示数据"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "AppData\*"; DestDir: "{app}\AppData"; Flags: ignoreversion recursesubdirs createallsubdirs
;ProjectData
文件夹内有演示企业的底稿文件,数据库初始化工具不能回复,暂时直接恢复;
;ProjectData
文件夹内有演示企业的底稿文件,
数据库初始化工具不能回复,暂时直接恢复;
;Source: "ProjectData\"; DestDir: "{app}\ProjectData"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "DataConvert\*"; DestDir: "{app}\DataConvert"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "DBUpdate\*"; DestDir: "{app}\DBUpdate"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "
升级包数据库升级脚本
\*"; DestDir: "{app}\DBUpdate\Script\"; Flags: ignoreversion recursesubdirs createallsubdirs
;
注册Office加载项,[run]段也加入bat文件注册双保险
Source: "
升级
包数据库升级脚本\*"; DestDir: "{app}\DBUpdate\Script\"; Flags: ignoreversion recursesubdirs createallsubdirs
;
注册Office加载项,[run]段也加
入bat文件注册双保险
Source: "DataConvert\Dts_dll\dtspkg.dll"; DestDir: "{app}\DataConvert\Dts_dll"; DestName: "dtspkg.dll"; Flags: regserver noregerror;
Source: "DataConvert\Dts_dll\dtspump.dll"; DestDir: "{app}\DataConvert\Dts_dll"; DestName: "dtspump.dll"; Flags: regserver noregerror;
;Office
加载项换成新方式
;Office
加载项
换成新方式
Source: "VSTO\*"; DestDir: "{app}\VSTO"; Flags: ignoreversion recursesubdirs createallsubdirs;
Source: "UFCPAS4Office\UFSY4Protocol.exe"; DestDir: "{app}\UFCPAS4Office"; Flags: ignoreversion recursesubdirs createallsubdirs;BeforeInstall: ClearTargetDir(ExpandConstant('{app}\UFCPAS4Office'))
;
注册Office加载项,[run]段也加入bat文件注册双保险
;
注册Office加载项,[run]段也加
入bat文件注册双保险
;Source: "UFCPAS4Office\libeay32.dll"; DestDir: "{app}\UFCPAS4Office"; DestName: "libeay32.dll"; Flags: regserver noregerror;
;Source: "UFCPAS4Office\ssleay32.dll"; DestDir: "{app}\UFCPAS4Office"; DestName: "ssleay32.dll"; Flags: regserver noregerror;
;
注册Office加载项,[run]段也加入bat文件注册双保险
;
注册Office加载项,[run]段也加
入bat文件注册双保险
;Source: "UFCPAS4Office\UFCPAS4Office-32.dll"; DestDir: "{app}\UFCPAS4Office"; DestName: "UFCPAS4Office.dll"; Flags: regserver noregerror; Check: not IsOffice64
;Source: "UFCPAS4Office\UFCPAS4Office-64.dll"; DestDir: "{app}\UFCPAS4Office"; DestName: "UFCPAS4Office.dll"; Flags: regserver noregerror; Check: IsOffice64
;
注册UFSYA.ocx,[run]段也加入bat文件注册双保险
;
注册UFSYA.ocx,[run]段也加入b
at文件注册双保险
;Source: "UFCPAS4Office\UFSYA-32.ocx"; DestDir: "{app}\UFCPAS4Office"; DestName: "UFSYA-32.ocx"; Flags: regserver noregerror 32bit;
;ource: "UFCPAS4Office\UFSYA-64.ocx"; DestDir: "{app}\UFCPAS4Office"; DestName: "UFSYA-64.ocx"; Flags: regserver noregerror 64bit; Check: IsWin64
;UFCPAS6.0
新增
;UFCPAS6.0新增
Source: "cpas-apps\*"; DestDir: "{app}\cpas-apps"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "locales\zh-CN.pak"; DestDir: "{app}\locales"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "locales\en-US.pak"; DestDir: "{app}\locales"; Flags: ignoreversion recursesubdirs createallsubdirs
...
...
@@ -125,18 +125,18 @@ Source: "LICENSE.electron.txt"; DestDir: "{app}"; Flags: ignoreversion
Source: "LICENSES.chromium.html"; DestDir: "{app}"; Flags: ignoreversion
Source: "resources.pak"; DestDir: "{app}"; Flags: ignoreversion
Source: "snapshot_blob.bin"; DestDir: "{app}"; Flags: ignoreversion
Source: "start-
日志
.bat"; DestDir: "{app}"; Flags: ignoreversion
Source: "start-
日
志.bat"; DestDir: "{app}"; Flags: ignoreversion
Source: "v8_context_snapshot.bin"; DestDir: "{app}"; Flags: ignoreversion
Source: "vk_swiftshader.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "vk_swiftshader_icd.json"; DestDir: "{app}"; Flags: ignoreversion
;Source: "SysBPL\midas.dll"; DestDir: "{app}\SysBPL"; Flags: ignoreversion regserver
;
先不打包审聊工具
;
先不
打包审聊工具
;Source: "UFAudChat\*"; DestDir: "{app}\UFAudChat";Excludes: "*\appdata\*"; Flags: ignoreversion recursesubdirs createallsubdirs
;
创建空目录
;
创建
空目录
[Dirs]
;Name: "{app}\2025"
...
...
@@ -157,17 +157,17 @@ Root: HKU; Subkey: ".default\software\{#MyAppRegName6}"; ValueType: string;
Root: HKU; Subkey: ".default\software\{#MyAppRegName6}"; ValueType: string; ValueName: "ExeName"; ValueData: "{#MyAppExeName6}"
Root: HKCU; Subkey: "Control Panel\International"; ValueType: string; ValueName: "sShortDate"; ValueData: "yyyy-MM-dd"
;
兼容性
;兼容性
root: HKCU ;Subkey: "Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers";ValueType: string; ValueName: "{#SQL_Path}\SQLQuery\isqlw.exe"; ValueData: "WINXPSP3 RUNASADMIN"
root: HKCU ;Subkey: "Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers";ValueType: string; ValueName: "{app}\{#MyAppExeName6}"; ValueData: "RUNASADMIN"
root: HKCU ;Subkey: "Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers";ValueType: string; ValueName: "{app}\UFCPAS4Office\
注册Office加载项
6.exe"; ValueData: "RUNASADMIN"
root: HKCU ;Subkey: "Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers";ValueType: string; ValueName: "{app}\UFCPAS4Office\
注册Offic
e加载项6.exe"; ValueData: "RUNASADMIN"
;CPAS
在线底稿查看工具
;CPAS
在线底
稿查看工具
;Root: HKCR; Subkey: "cpas"; ValueType: string; ValueData: "CPASWorkPaperViewer"
;Root: HKCR; Subkey: "cpas"; ValueType: string; ValueName:"URL Protocol"; ValueData: "{app}\CPASProtocol.exe"
;Root: HKCR; Subkey: "cpas\DefaultIcon"; ValueType: string; ValueData: "{app}\CPASProtocol.exe,1"
;Root: HKCR; Subkey: "cpas\shell\open\command"; ValueType: string; ValueData: """{app}\CPASProtocol.exe"" ""%1"""
;
或者只删除特定的 open 值(推荐)
;
或者只删除特定的 op
en 值(推荐)
Root: HKCU; Subkey: "Software\Microsoft\Office\16.0\Excel\Options"; ValueType: none; ValueName: "open"; Flags: deletevalue uninsdeletevalue;
Root: HKCU; Subkey: "Software\Microsoft\Office\15.0\Excel\Options"; ValueType: none; ValueName: "open"; Flags: deletevalue uninsdeletevalue;
Root: HKCU; Subkey: "Software\Microsoft\Office\14.0\Excel\Options"; ValueType: none; ValueName: "open"; Flags: deletevalue uninsdeletevalue;
...
...
@@ -175,7 +175,7 @@ Root: HKCU; Subkey: "Software\Microsoft\Office\14.0\Excel\Options"; ValueType: n
[INI]
;Filename: "{app}\config.ini"; Section: "config"; Key: "IsDebug"; string: "0"
;userConfig
默认值
;userConfig
默认
值
Filename: "{app}\Config\UserConfig.ini"; Section: "DBCONNECTION"; Key: "DBTYPE"; string: "MSSQL"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "DBCONNECTION"; Key: "SQLINSTANCE"; string: "{#SQL_ServerName}"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "DBCONNECTION"; Key: "SYSDATABASE"; string: "AudSys"; Flags: createkeyifdoesntexist
...
...
@@ -188,50 +188,50 @@ Filename: "{app}\Config\UserConfig.ini"; Section: "AppLoginServer"; Key: "zserve
;Filename: "{app}\Config\UserConfig.ini"; Section: "SystemFunction"; Key: "CanEdit"; string: "1"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "AuditReportOpt"; Key: "edittemplate"; string: "1"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "AuditReportOpt"; Key: "Psjjd"; string: "
第五部分 业务完成阶段工作底稿
"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "AuditReportOpt"; Key: "sjjd"; string: "
单体报告
"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "AuditReportOpt"; Key: "Psjjd"; string: "
第五部分 业务
完成阶段工作底稿"; Flags: createkeyifdoesntexist
Filename: "{app}\Config\UserConfig.ini"; Section: "AuditReportOpt"; Key: "sjjd"; string: "
单
体报告"; Flags: createkeyifdoesntexist
[Run]
Filename: "{app}\Tools\AudSQL2014Express_Setup(AudSQL2014
实例).exe";StatusMsg: "安装AudSQL2014数据库
"; Parameters: "/sp- /silent /norestart"; WorkingDir: "{app}"; Flags:runhidden;
Filename: "msiexec";StatusMsg: "
正在安装AudSQL2014数据库"; Parameters: "/i ""{app}\Tools\SQLServerNativeClient32.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /log ""{app}\Tools\SQLClient安装日志
.log"""; WorkingDir: "{app}"; Flags:runhidden; Check: not IsWin64 and not GetSQLClientIsInstall;
Filename: "msiexec";StatusMsg: "
正在安装AudSQL2014数据库"; Parameters: "/i ""{app}\Tools\SQLServerNativeClient64.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /log ""{app}\Tools\SQLClient安装日志
.log"""; WorkingDir: "{app}"; Flags:runhidden; Check: IsWin64 and not GetSQLClientIsInstall;
Filename: "net"; StatusMsg: "
正在启动数据库
"; Parameters: "start {#SQL_INSTANCE}"; Flags:runhidden nowait;
Filename: "{app}\Tools\AudSQL2014Express_Setup(AudSQL2014
实例).exe";StatusMsg: "安装AudSQL201
4数据库"; Parameters: "/sp- /silent /norestart"; WorkingDir: "{app}"; Flags:runhidden;
Filename: "msiexec";StatusMsg: "
正在安装AudSQL2014数据库"; Parameters: "/i ""{app}\Tools\SQLServerNativeClient32.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /log ""{app}\Tools\SQLClie
nt安装日志.log"""; WorkingDir: "{app}"; Flags:runhidden; Check: not IsWin64 and not GetSQLClientIsInstall;
Filename: "msiexec";StatusMsg: "
正在安装AudSQL2014数据库"; Parameters: "/i ""{app}\Tools\SQLServerNativeClient64.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /log ""{app}\Tools\SQLClie
nt安装日志.log"""; WorkingDir: "{app}"; Flags:runhidden; Check: IsWin64 and not GetSQLClientIsInstall;
Filename: "net"; StatusMsg: "
正
在启动数据库"; Parameters: "start {#SQL_INSTANCE}"; Flags:runhidden nowait;
;Filename: "{app}\RegWorkPaperViewer.bat"; WorkingDir: "{app}\SysBPL"; Flags:runhidden nowait;
;
双重注册 ;注册Office加载项,[file]段也加入bat文件注册双保险
;Filename: "{app}\UFCPAS4Office\32
位Office请执行我
.bat"; Parameters: "notpause"; WorkingDir: "{app}\UFCPAS4Office"; Flags:runhidden nowait runasoriginaluser 32bit; Check: not IsOffice64;
;Filename: "{app}\UFCPAS4Office\64
位Office请执行我
.bat"; Parameters: "notpause"; WorkingDir: "{app}\UFCPAS4Office"; Flags:runhidden nowait runasoriginaluser 64bit; Check: IsOffice64;
;Filename: "{app}\UFCPAS4Office\
注册Office加载项
6.exe" ; Parameters: "-s"; WorkingDir: "{app}\UFCPAS4Office";
;
双重注册 ;注册Office加载项,[file]段
也加入bat文件注册双保险
;Filename: "{app}\UFCPAS4Office\32
位Office请
执行我.bat"; Parameters: "notpause"; WorkingDir: "{app}\UFCPAS4Office"; Flags:runhidden nowait runasoriginaluser 32bit; Check: not IsOffice64;
;Filename: "{app}\UFCPAS4Office\64
位Office请
执行我.bat"; Parameters: "notpause"; WorkingDir: "{app}\UFCPAS4Office"; Flags:runhidden nowait runasoriginaluser 64bit; Check: IsOffice64;
;Filename: "{app}\UFCPAS4Office\
注册Offic
e加载项6.exe" ; Parameters: "-s"; WorkingDir: "{app}\UFCPAS4Office";
;cpas6.0 office
加载项
Filename: "{app}\Tools\vstor_redist.exe"; StatusMsg: "VSTool
工具
"; Parameters: "/q /s"; WorkingDir: "{app}";
Filename: "msiexec";StatusMsg: "
正在卸载cpas-report-office-addin.msi加载项"; Parameters: "/x ""{app}\Tools\cpas-report-office-addin.msi"" /qn /lv ""{app}\Tools\cpas-report-office-addin卸载日志
.log"""; WorkingDir: "{app}";
;Filename: "msiexec";StatusMsg: "
正在安装UFCPAS6加载项"; Parameters: "/i ""{app}\Tools\cpas-report-office-addin.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /lv ""{app}\Tools\cpas-report-office-addin安装日志
.log"""; WorkingDir: "{app}"; Flags:runhidden;
;cpas6.0 office加载项
Filename: "{app}\Tools\vstor_redist.exe"; StatusMsg: "VSTool工具"; Parameters: "/q /s"; WorkingDir: "{app}";
Filename: "msiexec";StatusMsg: "
正在卸载cpas-report-office-addin.msi加载项"; Parameters: "/x ""{app}\Tools\cpas-report-office-addin.msi"" /qn /lv ""{app}\Tools\cpas-report-office-a
ddin卸载日志.log"""; WorkingDir: "{app}";
;Filename: "msiexec";StatusMsg: "
正在安装UFCPAS6加载项"; Parameters: "/i ""{app}\Tools\cpas-report-office-addin.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /lv ""{app}\Tools\cpas-report-office-ad
din安装日志.log"""; WorkingDir: "{app}"; Flags:runhidden;
Filename: "msiexec";StatusMsg: "
正在安装UFCPAS6.1加载项"; Parameters: "/i ""{app}\Tools\cpasReport.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /lv ""{app}\Tools\cpas-report-office-addin6-cpasReport安装日志
.log"""; WorkingDir: "{app}"; Flags:runhidden;
Filename: "msiexec";StatusMsg: "
正在安装UFCPAS6.1加载项"; Parameters: "/i ""{app}\Tools\cpasReport.msi"" IACCEPTSQLNCLILICENSETERMS=YES /passive /lv ""{app}\Tools\cpas-report-office-addin6-cpasRep
ort安装日志.log"""; WorkingDir: "{app}"; Flags:runhidden;
Filename: "{app}\VSTO\RegeditVSTO.exe" ; Parameters: ""; WorkingDir: "{app}\VSTO";
;//
需要与DcefBrowser.bpl在同一个文件内,否则报错; add by csb 查账通不要
Filename: "{app}\Tools\DcefBrowser_Setup.exe";StatusMsg: "
安装导航图工具
"; Parameters: "/sp- /silent /norestart ""/DIR={app}\SysBPL"""; WorkingDir: "{app}"; Flags:runhidden;
;//
需要与DcefBrowser.bpl在同一个文件内,否则报错; add
by csb 查账通不要
Filename: "{app}\Tools\DcefBrowser_Setup.exe";StatusMsg: "
安装
导航图工具"; Parameters: "/sp- /silent /norestart ""/DIR={app}\SysBPL"""; WorkingDir: "{app}"; Flags:runhidden;
[UninstallRun]
;
停止相关服务
;
停止相
关服务
;;;;
;
卸载 Office 加载项
;
卸载 Office
加载项
Filename: "msiexec"; Parameters: "/x ""{app}\Tools\cpasReport.msi"" /qn"; Flags: runhidden
Filename: "{app}\VSTO\unInstallVsto.bat"; Parameters: "notpause"; Flags:runhidden; BeforeInstall: LogUninstallStep('Starting VSTO uninstallation') ;
[Icons]
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName6}"; WorkingDir: "{app}\SysBpl";IconFilename: "{app}\AppData\pic\main.ico"
Name: "{app}\
启动
{#MyAppName}"; Filename: "{app}\{#MyAppExeName6}"; WorkingDir: "{app}\SysBpl";IconFilename: "{app}\AppData\pic\main.ico"
;Name: "{app}\
注册
WorkPaperViewer"; Filename: "{app}\WorkPaperViewer.exe"; WorkingDir: "{app}\SysBpl" ; Parameters: "Reg"
;Name: "{app}\
启动
ConfigTool"; Filename: "{app}\ConfigTool.exe"; WorkingDir: "{app}\SysBpl";
Name: "{app}\启动{#MyAppName}"; Filename: "{app}\{#MyAppExeName6}"; WorkingDir: "{app}\SysBpl";IconFilename: "{app}\AppData\pic\main.ico"
;Name: "{app}\
注
册WorkPaperViewer"; Filename: "{app}\WorkPaperViewer.exe"; WorkingDir: "{app}\SysBpl" ; Parameters: "Reg"
;Name: "{app}\启动ConfigTool"; Filename: "{app}\ConfigTool.exe"; WorkingDir: "{app}\SysBpl";
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName6}"; WorkingDir: "{app}\SysBpl";IconFilename: "{app}\AppData\pic\main.ico"
;Name: "{group}\
项目管理工具
4"; Filename: "{app}\ProjectManager.exe"; WorkingDir: "{app}\SysBpl";IconFilename: "{app}\AppData\pic\main.ico"
Name: "{group}\CPAS6.0
数据库初始化
"; Filename: "{app}\SourceData\UFCPAS_Init.exe"; Parameters: "InstanceName=AudSql2014"
Name: "{group}\
卸载
{#MyAppName}"; Filename: "{uninstallexe}"
;Name: "{app}\UFCPAS4Office\
取消注册Office加载项6"; Filename: "{app}\UFCPAS4Office\注册Office加载项
6.exe";Parameters: "/u"
;Name: "{group}\
项
目管理工具4"; Filename: "{app}\ProjectManager.exe"; WorkingDir: "{app}\SysBpl";IconFilename: "{app}\AppData\pic\main.ico"
Name: "{group}\CPAS6.0
数据
库初始化"; Filename: "{app}\SourceData\UFCPAS_Init.exe"; Parameters: "InstanceName=AudSql2014"
Name: "{group}\
卸
载{#MyAppName}"; Filename: "{uninstallexe}"
;Name: "{app}\UFCPAS4Office\
取消注册Office加载项6"; Filename: "{app}\UFCPAS4Office\注册
Office加载项6.exe";Parameters: "/u"
[Code]
function KillExe(Exename: PAnsiChar):integer; external 'KillExe@files:UFCPASSetupDll.dll stdcall setuponly';
...
...
@@ -239,44 +239,44 @@ function ProcessIsRun(Exename: PAnsiChar):boolean; external 'ProcessIsRun@files
function GetExcelIsWin64(): Boolean; external 'GetExcelIsWin64@files:UFCPASSetupDll.dll stdcall setuponly';
procedure ClearTargetDir(TargetDir: string);
begin
Log('
清空目录判断逻辑执行
: ' + TargetDir)
Log('
清空目录判
断逻辑执行: ' + TargetDir)
if DirExists(TargetDir) then
begin
//
删除所有文件和子目录
//
删除所有
文件和子目录
if DelTree(TargetDir, True, True, True) then
Log('
成功清空目录
: ' + TargetDir)
Log('
成功清
空目录: ' + TargetDir)
else
Log('
清空目录失败
: ' + TargetDir);
Log('
清空目
录失败: ' + TargetDir);
end;
end;
var
LocalIsOffice64 :boolean;
//
换个函数,直接使用GetExcelIsWin64函数,会报
can't call proc
//
换个函数,直接使用GetExcelI
sWin64函数,会报can't call proc
function IsOffice64(): boolean;
begin
//
不能使用方法,直接不行
result := LocalIsOffice64
//
不能使用方
法,直接不行 result := LocalIsOffice64
if LocalIsOffice64 then
result := true
else
result := false;
end;
//
在安装程序初始化时调用,返回 False 中断安装,返回 True 反之。
//
在安装程序初始化时调用,返回 False 中
断安装,返回 True 反之。
function InitializeSetup (): Boolean;
begin
LocalIsOffice64 := GetExcelIsWin64();
//
删除 C:\Test 中的所有文件和目录 // 但保留它本身目录
//
删除 C:\Test 中的所有文件和目录
// 但保留它本身目录
{ if IsWin64 then
begin
MsgBox('64
位系统
', mbInformation, MB_OK);
MsgBox('64
位系统
', mbInformation, MB_OK);
end
else begin
MsgBox('32
位系统
', mbInformation, MB_OK);
MsgBox('32
位系统
', mbInformation, MB_OK);
end;
}
DeleteFile(ExpandConstant('{commondesktop}\
智审IAS作业平台
V1.0.lnk'));
DeleteFile(ExpandConstant('{commondesktop}\
智审IAS作业平台
V6.0.lnk'));
DeleteFile(ExpandConstant('{commondesktop}\
智审IAS作
业平台V1.0.lnk'));
DeleteFile(ExpandConstant('{commondesktop}\
智审IAS作
业平台V6.0.lnk'));
result := true;
end;
...
...
@@ -285,7 +285,7 @@ begin
result:= RegKeyExists(HKEY_LOCAL_MACHINE, 'SOFTWARE\Classes\CLSID\{8F4A6B68-4F36-4e3c-BE81-BC7CA4E9C45C}\ProgID');
end;
//
默认安装路径
//
默认安装
路径
function GetDefaultDir(Param: String): String;
var
OldPath,NewDrive:String;
...
...
@@ -293,13 +293,13 @@ var
i:integer;
begin
if RegQueryStringValue(HKEY_USERS, '.default\software\'+ExpandConstant('{#MyAppRegName6}'),'Path', OldPath) then
begin //
如果安装过,覆盖安装
begin //
如果安装
过,覆盖安装
Result := OldPath;
end else
begin
T_FreeMB:=0; NewDrive:='C:\';
C_FreeMB:=0; C_TotalMB:=0;
for i:=67 to 77 do //c:~K:\
哪个盘空间大,就默认选择哪个盘
for i:=67 to 77 do //c:~K:\
哪个盘空间大,
就默认选择哪个盘
begin
GetSpaceOnDisk(Chr(i)+':\', True, C_FreeMB, C_TotalMB);
if C_FreeMB>T_FreeMB then
...
...
@@ -313,7 +313,7 @@ begin
end;
procedure SetEnv(aEnvName, aEnvValue: string; aIsInstall, aIsInsForAllUser: Boolean);//
设置环境变量函数
procedure SetEnv(aEnvName, aEnvValue: string; aIsInstall, aIsInsForAllUser: Boolean);//
设
置环境变量函数
var
sOrgValue: string;
S1, sFileName: string;
...
...
@@ -331,7 +331,7 @@ begin
sOrgValue := Trim(sOrgValue);
begin
S1 := aEnvValue;
if pos(Uppercase(s1), Uppercase(sOrgValue)) = 0 then //
还没有加入
if pos(Uppercase(s1), Uppercase(sOrgValue)) = 0 then //
还没
有加入
begin
if aIsInstall then
begin
...
...
@@ -359,7 +359,7 @@ begin
RegWriteStringValue(HKEY_CURRENT_USER, 'Environment', aEnvName, sOrgValue);
end;
end;
end else //
非NT 系统,如
Win98
end else //
非NT 系统
,如Win98
begin
...
...
@@ -370,8 +370,8 @@ procedure CurPageChanged ( CurPageID : Integer);
begin
end;
//
安装完成时
procedure CurStepChanged(CurStep: TSetupStep);//
设置日期格式,生效,日期格式是在 [Registry] 段设置的
//
安装
完成时
procedure CurStepChanged(CurStep: TSetupStep);//
设置日期格式,生效,日期格式是在 [Re
gistry] 段设置的
var ResultCode:integer; logfilepathname, logfilename, newfilepathname: string;
begin
logfilepathname := ExpandConstant('{log}');
...
...
@@ -382,10 +382,10 @@ begin
begin
PostMessage (HWND_BROADCAST,$001A, 0,0);//$001A=WM_SETTINGCHANGE SendMessage hui si ji
SetEnv('path',ExpandConstant('{app}\SysBpl'),true,true); //
在这儿调用,一定在这儿调用,安装完无须重启,立即生效
SetEnv('path',ExpandConstant('{app}\SysBpl'),true,true); //
在这儿调用,
一定在这儿调用,安装完无须重启,立即生效
Exec('cmd.exe',ExpandConstant('/c "set Path={app}\SysBPL"'),'',SW_Hide,ewNoWait, ResultCode);//
环境变量生效
//
改变Win10下文件拖放到底稿平台,不起作用
Exec('cmd.exe',ExpandConstant('/c "set Path={app}\SysBPL"'),'',SW_Hide,ewNoWait, ResultCode);//
环
境变量生效
//
改变Win10下文件拖放
到底稿平台,不起作用
RegWriteDWordValue(HKEY_LOCAL_MACHINE, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System', 'EnableLUA', 0);
// msgBox(ExpandConstant('{app}\SysBpl'), mbInformation, MB_OK);
...
...
@@ -395,28 +395,28 @@ begin
if CurStep=ssInstall then
begin
Exec('net', ExpandConstant('stop {#SQL_INSTANCE}'), '', SW_Hide,ewWaitUntilTerminated, ResultCode);
DelTree(ExpandConstant('{app}\resources'), False, True, True); // add by zyp 23-06-14
删除原来的resources,整个目录替换
DelTree(ExpandConstant('{app}\CpasCloudSvr'), False, True, True); // add by zyp 23-07-01 sqlite
表结构有调整
DelTree(ExpandConstant('{app}\AppData\Files\
报告模版'), False, True, True); //报告模版 需清楚旧模板
DelTree(ExpandConstant('{app}\AppData\Files\
底稿模板'), False, True, True); //询证函模板 需清楚旧模板
//DelTree(ExpandConstant('{app}\AppData\Nav'), False, True, True); //
询证函模板 需清楚旧模板
DelTree(ExpandConstant('{app}\
演示数据'), False, True, True); //询证函模板 需清楚旧模板
DelTree(ExpandConstant('{app}\
审计指引临时目录
'), False, True, True);
DelTree(ExpandConstant('{app}\DBUpdate'), False, True, True); //
删除老脚本,避免某些老的升级脚本误执行
// DelTree(ExpandConstant('{app}\AppData\Files\
询证函模版'), False, True, True); //12.08培训后 此行不要
DelTree(ExpandConstant('{app}\resources'), False, True, True); // add by zyp 23-06-14
删除原来的resources
,整个目录替换
DelTree(ExpandConstant('{app}\CpasCloudSvr'), False, True, True); // add by zyp 23-07-01 sqlite
表结
构有调整
DelTree(ExpandConstant('{app}\AppData\Files\
报告模版'), False, True, True); //
报告模版 需清楚旧模板
DelTree(ExpandConstant('{app}\AppData\Files\
底稿模板'), False, True, True); //询证函
模板 需清楚旧模板
//DelTree(ExpandConstant('{app}\AppData\Nav'), False, True, True); //
询证函模板
需清楚旧模板
DelTree(ExpandConstant('{app}\
演示数据'), False, True, True); //询证
函模板 需清楚旧模板
DelTree(ExpandConstant('{app}\
审计指引
临时目录'), False, True, True);
DelTree(ExpandConstant('{app}\DBUpdate'), False, True, True); //
删除老脚本,避免
某些老的升级脚本误执行
// DelTree(ExpandConstant('{app}\AppData\Files\
询证函模版'), False, True, True); //12.08培训
后 此行不要
end else
if CurStep=ssDone then
begin //
暂时不行,找不到
bpl
begin //
暂时不
行,找不到bpl
//ShellExec('open',ExpandConstant('{app}\{#MyAppExeName}'),'', ExpandConstant('{app}\SysBpl'), SW_Hide,ewNoWait, ResultCode)
FileCopy(logfilepathname, newfilepathname, false);
ShellExec('open',ExpandConstant('{app}\SourceData\UFCPAS_Init.exe'),'InstanceName=AudSql2014 autoini', ExpandConstant('{app}'), SW_Show,ewWaitUntilTerminated, ResultCode)
//
完成后执行数据初始化
//
完成后执
行数据初始化
end;
end;
//
非法字符可能引起SQLServer语句出现问题
add by csb 2017-10-30
//
非法字符可能引起SQL
Server语句出现问题 add by csb 2017-10-30
function ExistsInvalidChar(str:string):boolean;
begin
result := (pos('''', str) >0 )
...
...
@@ -434,12 +434,12 @@ var
aProcessIsRun: boolean;
// ResultCode:integer;
begin
if (CurPageID = wpSelectDir) then//
选择路径的界面,点击下一步时执行
add by csb 2017-10-30
if (CurPageID = wpSelectDir) then//
选择路径的界面
,点击下一步时执行 add by csb 2017-10-30
begin
result :=not ExistsInvalidChar(ExpandConstant('{app}'));
if not result then
begin
MsgBox('
文件夹名不能包含下列任何字符
:'+#13#10+#13#10+'/ : * ? " < > | '' ! ', mbCriticalError, MB_OK);
MsgBox('
文件夹名
不能包含下列任何字符:'+#13#10+#13#10+'/ : * ? " < > | '' ! ', mbCriticalError, MB_OK);
Exit;
end;
...
...
@@ -447,7 +447,7 @@ begin
or ProcessIsRun('cpas-WorkPlatform.exe');
if aProcessIsRun then
begin
result := ( MsgBox('
必须关闭正在运行的审计软件才能继续,是否关闭正在运行的软件?
', mbConfirmation, MB_YESNO) = IDYES );
result := ( MsgBox('
必须关闭正在
运行的审计软件才能继续,是否关闭正在运行的软件?', mbConfirmation, MB_YESNO) = IDYES );
if result then
begin
KillExe('UFCPAS4.exe');
...
...
@@ -467,22 +467,22 @@ begin
SaveStringToFile(ExpandConstant('{app}\uninstall_detailed.log'), '[' + GetDateTimeString('yyyy/mm/dd hh:nn:ss', '-', ':') + '] ' + Step + #13#10, True);
end;
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);//
删除环境变量
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);//
删
除环境变量
begin
case CurUninstallStep of
usUninstall:
begin
//
用户点击"卸载"后立即执行
//
此时文件还未开始删除
// MsgBox('
开始卸载
...', mbInformation, MB_OK);
// Filename: "msiexec";StatusMsg: "
正在卸载cpas-report-office-addin.msi加载项"; Parameters: "/x ""{app}\Tools\cpas-report-office-addin.msi"" /qn /lv ""{app}\Tools\cpas-report-office-addin卸载日志
.log"""; WorkingDir: "{app}";
//
用户点击"
卸载"后立即执行
//
此时文件还
未开始删除
// MsgBox('
开始
卸载...', mbInformation, MB_OK);
// Filename: "msiexec";StatusMsg: "
正在卸载cpas-report-office-addin.msi加载项"; Parameters: "/x ""{app}\Tools\cpas-report-office-addin.msi"" /qn /lv ""{app}\Tools\cpas-report-office-a
ddin卸载日志.log"""; WorkingDir: "{app}";
end;
usPostUninstall:
begin
//
所有文件删除完成后执行
//
此时安装目录已被移除
//
所有文件
删除完成后执行
//
此时安装目录
已被移除
SetEnv('path',ExpandConstant('{app}\SysBpl'),false,true);
end;
end;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment