1
我在inno setup中创建了自定义页面。它有5个文本框用于特定目的。我想检索脚本中的值(如用户输入的那样)以进行额外的工作,例如注册,创建文件夹等。 任何人都可以请建议如何检索脚本中的值页面和控件?Inno Setup - 检索自定义值
我在inno setup中创建了自定义页面。它有5个文本框用于特定目的。我想检索脚本中的值(如用户输入的那样)以进行额外的工作,例如注册,创建文件夹等。 任何人都可以请建议如何检索脚本中的值页面和控件?Inno Setup - 检索自定义值
您应该看看Inno Setup中安装的示例脚本CodeDlg.iss
。我假设你使用CreateInputQueryPage
功能的五个文本框创建自定义的页面,如CodeDlg.iss
:
UserPage := CreateInputQueryPage(wpWelcome,
'Personal Information', 'Who are you?',
'Please specify your name and the company for whom you work, then click Next.');
UserPage.Add('Name:', False);
UserPage.Add('Company:', False);
然后使用
UserPage.Values[0]
访问第一个编辑框的值, UserPage.Values[1]
来访问第二个数据,依此类推。
+1你打我20秒!!! – jachguate 2011-03-29 15:40:21
如果我想在这个inputquery页面上添加一个新按钮怎么办? – cdp 2011-05-24 20:44:56
chirag,你可以利用创建按钮并分配必要的坐标..类似这样的东西。 ConnectButton:= TButton.Create(WizardForm); ConnectButton.Parent:= WizardForm; ConnectButton.Left:= 8; ConnectButton.Top:= WizardForm.ClientHeight - ConnectButton.ClientHeight - 8; ConnectButton.Caption:='连接'; ConnectButton.OnClick:= @ConnectButtonClick; – anand 2012-11-07 09:08:04