T
tomol
Unregistered / Unconfirmed
GUEST, unregistred user!
VC里的原型是:
__declspec(dllexport) int __stdcall SaveHtmAsMht(CString szPageURL, CString szFileName, CString& szErrMsg)
在Delphi中是:
implementation
function SaveHtmAsMht(szPageURL:string;szFileName:string;var szErrMsg:string):integer;stdcall; external 'savetomht.dll';
调用时
procedure TForm1.Button2Click(Sender: TObject);
var
i:integer;
str:String;
begin
str:='test';
i:=SaveHtmAsMht('www.gznet.com', 'd:/mytest.mht', str);//这行出错
end;
出现如下错误:
Project Project1.exe raised exception class EAccessViolation with message 'Access violation at address 77E66663 in module 'kernel32.dll'. Write of address 00401F3C'. Process stopped. Use Step or Run to continue.
请高手指点!!!
__declspec(dllexport) int __stdcall SaveHtmAsMht(CString szPageURL, CString szFileName, CString& szErrMsg)
在Delphi中是:
implementation
function SaveHtmAsMht(szPageURL:string;szFileName:string;var szErrMsg:string):integer;stdcall; external 'savetomht.dll';
调用时
procedure TForm1.Button2Click(Sender: TObject);
var
i:integer;
str:String;
begin
str:='test';
i:=SaveHtmAsMht('www.gznet.com', 'd:/mytest.mht', str);//这行出错
end;
出现如下错误:
Project Project1.exe raised exception class EAccessViolation with message 'Access violation at address 77E66663 in module 'kernel32.dll'. Write of address 00401F3C'. Process stopped. Use Step or Run to continue.
请高手指点!!!