R
rsina
Unregistered / Unconfirmed
GUEST, unregistred user!
在DLL中动态的使用idhttp控件编译不通过,是方法不对,还是我DLL编写的有问题啊?
unit search;
interface
uses
SysUtils,
Classes,
IdHTTP,
IdBaseComponent,
IdComponent,
IdTCPClient,
IdTCPConnection;
function search(DLLHandle: THandle
search_string: String
search_start,search_stop:String;
search_option:String): Boolean
export;
implementation
function search(DLLHandle: THandle
search_string: String
search_start,search_stop:String
search_option:String): Boolean;
var
idhttp: TIdhttp;
temp: String;
begin
idhttp := TIdhttp.Create(nil);
idhttp.Host := 'www.sina.com.cn';
idhttp.Port := 80;
temp := idhttp.Get('http://www.sina.com.cn'+search_string);
idhttp.Free;
result :=TRUE;
end;
end.
unit search;
interface
uses
SysUtils,
Classes,
IdHTTP,
IdBaseComponent,
IdComponent,
IdTCPClient,
IdTCPConnection;
function search(DLLHandle: THandle
search_string: String
search_start,search_stop:String;
search_option:String): Boolean
export;
implementation
function search(DLLHandle: THandle
search_string: String
search_start,search_stop:String
search_option:String): Boolean;
var
idhttp: TIdhttp;
temp: String;
begin
idhttp := TIdhttp.Create(nil);
idhttp.Host := 'www.sina.com.cn';
idhttp.Port := 80;
temp := idhttp.Get('http://www.sina.com.cn'+search_string);
idhttp.Free;
result :=TRUE;
end;
end.