; Script generated by the Inno Setup Script Wizard. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! #define MyAppName "蘭雅CorelVBA 2023版" #define MyAppVersion "1.1" #define MyAppPublisher "蘭雅sRGB CorelDRAW 免费开源插件" #define MyAppURL "https://262235.xyz/" #define MyAppExeName "GMS" #define MyAppAssocName MyAppName + "" #define MyAppAssocExt ".myp" #define MyAppAssocKey StringChange(MyAppAssocName, " ", "") + MyAppAssocExt [Setup] ; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications. ; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) AppId={{0006790C-7107-4C59-A557-7F2EEDB64AFB} AppName={#MyAppName} AppVersion={#MyAppVersion} ;AppVerName={#MyAppName} {#MyAppVersion} AppPublisher={#MyAppPublisher} AppPublisherURL={#MyAppURL} AppSupportURL={#MyAppURL} AppUpdatesURL={#MyAppURL} ChangesAssociations=yes DisableProgramGroupPage=yes ; Uncomment the following line to run in non administrative install mode (install for current user only.) ;PrivilegesRequired=lowest OutputDir=C:\app\CorelVBA OutputBaseFilename=蘭雅CorelVBA SetupIconFile=C:\app\CorelVBA\GMS\262235.xyz\蘭.ico Compression=lzma SolidCompression=yes WizardStyle=modern UsePreviousAppDir=no DefaultDirName={code:GetInstallDir} [Code] function GetInstallDir(Param: String): String; var InstallDir: String; begin // 从注册表中读取安装目录 if RegQueryStringValue(HKLM64, 'SOFTWARE\Corel\Setup\CorelDRAW Graphics Suite 2022', 'Destination', InstallDir) then begin Result := ExtractFilePath(InstallDir) + 'Draw\GMS'; end else if RegQueryStringValue(HKLM64, 'SOFTWARE\Corel\Setup\CorelDRAW Graphics Suite 2020', 'Destination', InstallDir) then begin Result := ExtractFilePath(InstallDir) + 'Draw\GMS'; end else if RegQueryStringValue(HKLM64, 'SOFTWARE\Corel\Setup\CorelDRAW Graphics Suite 16', 'Destination', InstallDir) then begin Result := ExtractFilePath(InstallDir) + 'Draw\GMS'; end else begin // 如果读取失败,则使用默认安装目录 Result := ExpandConstant('C:\Program Files\Corel\CorelDRAW Graphics Suite 2020\Draw\GMS'); end; end; [Languages] Name: "chinesesimplified"; MessagesFile: "compiler:Languages\ChineseSimplified.isl" [Tasks] Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked [Files] Source: "C:\app\CorelVBA\GMS\262235.xyz.gms"; DestDir: "{app}"; Flags: ignoreversion Source: "C:\app\CorelVBA\GMS\Adobe_Illustrator.gms"; DestDir: "{app}"; Flags: ignoreversion Source: "C:\app\CorelVBA\GMS\ColorMark.cdr"; DestDir: "{app}"; Flags: ignoreversion Source: "C:\app\CorelVBA\GMS\ZeroBase.gms"; DestDir: "{app}"; Flags: ignoreversion Source: "C:\app\CorelVBA\GMS\学习CorelVBA.gms"; DestDir: "{app}"; Flags: ignoreversion ; NOTE: Don't use "Flags: ignoreversion" on any shared system files Source: "C:\app\CorelVBA\GMS\262235.xyz\*"; DestDir: "{app}\262235.xyz\"; Flags: ignoreversion Source: "C:\app\CorelVBA\TSP\*"; DestDir: "C:\TSP\"; Flags: ignoreversion [Icons] Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon [Run] ;Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: shellexec postinstall skipifsilent