查看了MSDN的资料,说明如下:
命令格式:ExecWB(OLECMDID_SAVEAS,nCmdExecOpt , pvaIn,pvaOut );
参数如下:
This command displays a dialogue box if the nCmdExecOpt argument of IOleCommandTarget::Exec is set to MSOCMDEXECOPT_DODEFAULT, MSOCMDEXECOPT_PROMPTUSER, or NULL. It does not display a dialogue box if the argument is set to MSOCMDEXECOPT_DONTPROMPTUSER.
pvaIn VARIANT of type VT_BSTR that specifies the path and file name of the file to which to save the Web page. When the path contains more than one folder name, separate the folder names with two backward slashes (//).
pvaOut Set to NULL.
按照上面的说明,我下面的代码应该就不会弹出对话框了,但实际运行还是出现了,真头痛!
var
v: OleVariant ;
begin
v:='c://tt.htm';
WebBrowser1.ExecWB(OLECMDID_SAVEAS,OLECMDEXECOPT_DONTPROMPTUSER,v,EmptyParam);
end;
有没有人帮帮我啊? 无助的我静静的等待着。。。。。