function GetLocalIP : String; var WSAData: TWSAData; HostName, IPAddress: String; HostEnt: PHostEnt; begin WSAStartup(2, WSAData); SetLength(HostName, 255); GetHostname(PChar(HostName), 255); SetLength(HostName, StrLen(PChar(HostName))); HostEnt := GetHostByName(PChar(HostName)); with HostEnt^ do IPAddress := Format('%d.%d.%d.%d',[Byte(h_addr^[0]), Byte(h_addr^[1]), Byte(h_addr^[2]), Byte(h_addr..