On Dec 21, 2004, at 2:14 AM, Thierry Arbellot wrote:

2 tricks for OS X and Win 2K
theIPAddress is the local IP address of the computer

MacOS X
put replaceText(shell("/sbin/ifconfig en0 | head -3 | grep 'inet ' | cut -d' ' -f 2"),"(\s|\(|\))","") into theIPAddress


Windows 2000/XP
    put "255.255.255.255:43222" into testSocket
    open datagram socket to testSocket
    put hostAddress(testSocket) into theIPAddress
    close socket testSocket

I think with 2.5, the latter will work on OS X! It did just now on my system & Revolution 2.5, anyway. Yay!


I'm too lazy to turn on the Mac OS 9 at the moment.

Dar
**********************************************
    DSC (Dar Scott Consulting & Dar's Lab)
    http://www.swcp.com/dsc/
    Programming Services and Software
**********************************************

_______________________________________________
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to