In our previous episode, Felipe Monteiro de Carvalho said: > function ChessGetLocalIP(): string;
> VProcess.CommandLine := > 'sh -c "ifconfig eth0 | awk ''/inet end/ {print $3}''"'; Fails if eth0 is not the primary NIC. Doesn't work on non-linux (that use other ethernet naming schemes) A safe solution will probably boil down to walking the list of ethernet adapters and routes to find the default route on *nix. _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal