德尔福中的OLE错误805303E?
|
你好
我正在测试在geckobrowser(Delphi中的gecko组件)中加载html代码的功能。
这里的功能
procédure TCustomGeckoBrowser.LoadHTML (htmlCode: string);
var
domwindow: nsIDOMWindow;
domdoc: nsIDOMDocument;
domhtmldoc: nsIDOMHTMLDocument;
nsstr: IInterfacedString;
begin
domwindow: = GetContentWindow;
domdoc: = GetContentDocument;
domhtmldoc: = domdoc que nsIDOMHTMLDocument;
nsstr: = nouvelleChaine;
nsstr.Assign (htmlCode);
domhtmldoc.Write (nsstr.AString);
end;
但是程序显示类型为“ OLE ERROR 805303E8”的错误。我跟踪了执行情况,发现问题所在:domhtmldoc.Write (nsstr.AString)
函数“ write \”在我的组件的接口中声明:
nsIDOMHTMLDocument = interface(nsIDOMDocument)
procedure Writeln(const text: nsAString); safecall;
.....
end;
您遇到过这样的错误吗?
没有找到相关结果
已邀请:
1 个回复
蕉衫