InnoSetup 卸载询问消息 - Pascal 编码
我已经为我的一些游戏创建了一个安装程序,我希望卸载程序询问我是否要保存我的游戏文件。 像这样的事情:当我执行 uninstall.exe 时询问我“您想保留所有已保存的游戏吗?”是还是不是。如果我点击“是”,我的保存文件将保留,并且我的程序文件将被卸载;如果我点击“否”,我的程序文件(包括保存文件)将被卸载。 InnoSetup 执行此操作的 PASCAL 代码是什么?
非常感谢!
I have created an installer for some of my games and I want the uninstaller to ask me if I want to save my game files.
Something like this: when I execute the uninstall.exe to ask me 'Do you want to keep all saved games?' YES or NO. If I hit YES my save files remain and my program files are uninstalled and if I hit NO my program files inclusive save files to be uninstalled.
What is the PASCAL code for InnoSetup to do this?
Thank you very much!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以执行以下操作:
您可能希望使用最新版本的 InnoSetup,因为这就是我测试过的版本。上面的示例基于 InnoSetup 编译器附带的 UninstallCodeExample.iss。
我添加了一行代码来演示如何删除文件。它调用删除文件函数。您需要为卸载时要删除的每个不在 [Files] 部分中的文件添加一个删除文件。
You can do something like:
You would want to use the latest version of InnoSetup as that's what I tested with. The sample above is based on the UninstallCodeExample.iss included with the InnoSetup compiler.
I added a line of code to show how to delete a file. It calls the DeleteFile function. You would need to add a DeleteFile for each file you want to remove at uninstall that isn't in your [Files] section.
可能与您的问题有关,如果您只想将卸载消息更改为“您确定要完全删除 %1 及其所有组件吗?”对于其他内容,您可以通过修改其消息来完成此操作,例如
参考: http: //www.jrsoftware.org/ishelp/index.php?topic=messagessection
Possibly related to your question, if you just want to change the uninstall message from "Are you sure you want to completely remove %1 and all of its components?" to something else, you can do this by modifying its message, like
ref: http://www.jrsoftware.org/ishelp/index.php?topic=messagessection