Re: IP of a connected Mac
Re: IP of a connected Mac
- Subject: Re: IP of a connected Mac
- From: Smith Kennedy <email@hidden>
- Date: Mon, 6 Jan 2003 12:23:02 -0700
That's true, and it is unfortunate that the code snippet I threw out
there won't return the "default" interface. Seems like a logical thing
for that method to return, but the documentation says it will be "an
arbitrary Internet address of the receiver".
On Monday, January 6, 2003, at 11:12 AM, Joshua Graessley wrote:
That will not work. It is important to note that the computer may have
more than one IP address on more than one interface. The code below
would only return one IP address.
-josh
On Monday, January 6, 2003, at 07:38 AM, Smith Kennedy wrote:
This might work:
NSString *myAddress = [[NSHost currentHost] address];
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.