我使用Inno Setup创建我的第一个安装程序。
但是,当启动安装程序时,在让Windows屏幕询问执行此文件的权限之前,我得到了一个带有以下错误的窗口:



英文(来自WinError.h):



然后启动安装程序。但是,大约10秒钟后,它会自行再次启动。

这是我的iss文件:

; Script generated by the Inno Script Studio Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define MyAppName "Facturation"
#define MyAppVersion "1.0"
#define MyAppPublisher "JoWe"
#define MyAppURL "http://www.jowe.fr/"
#define MyAppExeName "facturation.exe"

[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={{B8DF3E83-4622-48AB-9DD5-C75D4951BEDE}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\Facturation
DefaultGroupName=Facturation
OutputDir=E:\Téléchargements
OutputBaseFilename=setup
SetupIconFile=D:\apps\vivemus\vivemus.com\resources\img\favicon.ico
Compression=lzma
SolidCompression=yes

[Languages]
Name: "french"; MessagesFile: "compiler:Languages\French.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked

[Files]
Source: "D:\Logiciels\phpdesktop-chrome-31.8-php-5.6.1\phpdesktop-chrome.exe"; DestDir: "{app}"; Flags: ignoreversion

[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon

[Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent

即使使用向导创建新的安装程序,我也有此问题。我已经向Inno Studio添加了一个日志,但是它只有编译日志,没有错误。

有谁知道这个问题的根源?

最佳答案

一位同事遇到了同样的问题。原来,病毒扫描Avast是造成此问题的原因。禁用病毒扫描,然后运行安装程序而没有任何问题。

关于inno-setup - 启动使用Inno Setup创建的安装程序时,ShellExecuteEx错误299,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/35130522/

10-12 05:43