首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > .NET > .NET >

怎么获取外网下网地址IP(非本机IP)

2012-09-17 
如何获取外网上网地址IP(非本机IP)如何获取外网上网地址IP(非本机IP)[解决办法]Delphi(Pascal) codeuses I

如何获取外网上网地址IP(非本机IP)
如何获取外网上网地址IP(非本机IP)

[解决办法]

Delphi(Pascal) code
uses IdHTTP;procedure TForm1.Button1Click(Sender: TObject);var s:string;    idhttp:Tidhttp;begin  idhttp:=Tidhttp.Create(self);  try    s:=idhttp.Get('http://city.ip138.com/city0.asp');    showmessage(copy(s,pos('[',s)+1,pos(']',s)-pos('[',s)-1));  finally    idhttp.Free;  end;end; 

热点排行