以下部分代码是本论坛搜索到的,用这个代码卸载程序后可以打开网址,但有个问题是,他在卸载还未退出程序就打开了,我想问的是能不能在卸载完成单击“确定”按钮之后再打开此网址?请大伙给个说法。谢谢。
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
var
ErrorCode: Integer;
begin
case CurUninstallStep of
usUninstall:
begin // 开始卸载
end;
usPostUninstall:
begin // 卸载完成
ShellExec('open', 'http://www.baidu.com', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
end;
end;
end;