function void SetupSuccess()
STRING szTitle;
STRING szMsg1, szMsg2,szOpt1,szOpt2;
BOOL bvOpt1, bvOpt2;
STRING szApplicationPath,szApplicationCmdLine,szCmdLine;
begin
// if (MAINTENANCE) then return 0;endif;//如果不是安装状态,比如修改/卸载状态的时候,则不执行。
if REMOVEALLMODE = 0 then
szTitle = "Install success ";//对话框的标题
szMsg1 = "%P Install success.\n" +
"Please choice:";//%P为软件名称
szMsg2 = "click 'finish'";
szOpt1 = "Read readme file ";//如果这里为空,则表示只有一个选项
szOpt2 = "Run application";
SdFinish (szTitle, szMsg1, szMsg2, szOpt1, szOpt2, bvOpt1, bvOpt2);
if (bvOpt1) then
LaunchApp ('notepad.exe',INSTALLDIR ^ "\\readme.txt");//LaunchApp 用来运行某外部程序
endif;
if (bvOpt2) then
LaunchApp ("explorer.exe","http://localhost/AlohaWebClient");
endif;
endif;
end;如何处理呢?搜索了下没结果的.
我是想在安装成功后让用户选择"readme文件" 但不是在onmoved 的时候执行.
STRING szTitle;
STRING szMsg1, szMsg2,szOpt1,szOpt2;
BOOL bvOpt1, bvOpt2;
STRING szApplicationPath,szApplicationCmdLine,szCmdLine;
begin
// if (MAINTENANCE) then return 0;endif;//如果不是安装状态,比如修改/卸载状态的时候,则不执行。
if REMOVEALLMODE = 0 then
szTitle = "Install success ";//对话框的标题
szMsg1 = "%P Install success.\n" +
"Please choice:";//%P为软件名称
szMsg2 = "click 'finish'";
szOpt1 = "Read readme file ";//如果这里为空,则表示只有一个选项
szOpt2 = "Run application";
SdFinish (szTitle, szMsg1, szMsg2, szOpt1, szOpt2, bvOpt1, bvOpt2);
if (bvOpt1) then
LaunchApp ('notepad.exe',INSTALLDIR ^ "\\readme.txt");//LaunchApp 用来运行某外部程序
endif;
if (bvOpt2) then
LaunchApp ("explorer.exe","http://localhost/AlohaWebClient");
endif;
endif;
end;如何处理呢?搜索了下没结果的.
我是想在安装成功后让用户选择"readme文件" 但不是在onmoved 的时候执行.
解决方案 »
- VS2010 winform中 usercontrol 怎么放到窗体上
- Wince下,控件ListView的事件问题
- 制作安装程序过程中关于数据库的处理方法
- 加事件的时候用new的和不用new 的有什么区别?
- c# winform项目发布 按步骤创建了安装部署工程,但在“添加项目输出组”对话框的“项目”下拉列表看不到任何项目?
- 跪求(代码大全第二版电子版)下载地址,顶者有分 ^_^
- ShowModeDialog()的问题。。。。
- 关于两个DataList嵌套问题(解决主分类),主要用DataList1_ItemDataBound事件!
- 急急!!!!!!!!!保存listbox所有项的值的问题!!!!!!!
- 一个关于Visual C# Windows编程的问题
- 如何获得每英寸有多少个像素?
- 求解Utf-8编码下url传递参数部分丢失的问题!
现在我运行安装的时候总不能安装成功,估计是SetupSuccess的问题.把void去掉了也不行的.
怎么会这样?
-------------是我没说明白,我要实现的功能是在安装成功后,显示一个页面,该页面上有两个复选框(1)查看readme(2)运行程序.以前我看的你的一个代码例子是写在OnMoved里的.但是我不想写在里面,而是想写在安装程序正确安装后.
我把void去掉了,安装的时候只是说安装被中断,我不知道哪里的问题. 你帮我找找OK?
begin
MessageBox ("OnFirstUIBefore", INFORMATION);
end;
//
// 函数: OnFirstUIAfter
//
// 事件: FirstUIAfter event is sent after file transfer, when installation
// is run for the first time on given machine. In this event handler
// installation usually displays UI that will inform end user that
// installation has been completed successfully.
//
///////////////////////////////////////////////////////////////////////////////
function OnFirstUIAfter()
STRING szTitle,szMsg1, szMsg2, szOption1, szOption2,szCmdLine;
NUMBER bOpt1, bOpt2;begin
//set_vod_liveaddress();szCmdLine = SUPPORTDIR ^"SCE10CHS.EXE";
if (LaunchAppAndWait(szCmdLine, " /q",WAIT) < 0) then
MessageBox ("不能安装解码程序,请联系供应商.",SEVERE);
endif;Disable(STATUSEX);
bOpt1 = FALSE;
bOpt2 = FALSE;
szMsg1 = SdLoadString(IFX_SDFINISH_MSG1);
szMsg2 = "请浏览本主机WEB服务器上的 "+@PRODUCT_NAME+" 虚拟目录 例: http://Localhost/";
szOption1 = "";
szOption2 = "";
szTitle = @PRODUCT_NAME+"安装完成";
SdFinishEx(szTitle,szMsg1,szMsg2,szOption1,szOption2,bOpt1,bOpt2);szCmdLine = "http://LocalHost";
//if (LaunchApp(PROGRAMFILES ^"Internet Explorer"^"IEXPLORE.EXE", szCmdLine) < 0) then
//MessageBox ("不能打开浏览器.",SEVERE);
//endif;return 0;
end;