我在我的设置中添加了一些自定义页面。在其中一个自定义页面中,我进行了一些检查。如果此检查失败,我想切换到完成页面。我怎样才能做到这一点?
我不能使用ShouldSkipPage事件函数执行此操作,因为:
function ShouldSkipPage(PageID: Integer): Boolean;
begin
// this will NEVER happened - see documentation below
if (PageID = wpInstalling) or (PageID = wpPreparing) or (PageID = wpWelcome) then
begin
// skip install - simply for example
result := True;
exit;
end;
resutl := false;
end;
来自 Inno Setup 文档:
向导调用此事件函数来确定是否应该显示特定页面(由 PageID 指定)。如果返回True,则页面将被跳过;如果您返回 False,则可能会显示该页面。
注意:不会为wpWelcome、wpPreparing 和 wpInstalling 页面调用 此事件函数,也不会为安装程序已确定应跳过的页面(例如,不包含组件的安装中的 wpSelectComponents)调用此事件函数。