如何获取外网上网地址IP(非本机IP)
如何获取外网上网地址IP(非本机IP)
[解决办法]
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;