on 1/2/01 3:10 PM, [EMAIL PROTECTED] at
[EMAIL PROTECTED] wrote:
> I'm working on a chat program, bolstered by the help
> of others on the list. I want to get the IP address of
> the person chatting with me, even if they don't know
> how to get it themselves. I investigated hostAddress
> and peerAddress but ran into a puzzle -- can anyone
> explain it?
I have just implemented that feature. This is what I did.
--FIGURE SENDERS IP ADDRESS
set the itemdel to "|"
put item 1 of s & " " into field "whatever"
The s variable contains the other person's ip information. This should be
placed somewhere after the read command. I think it must be in the same
handler as the read command though.
Hope this helps some.
-Mark Talluto
>
> I'm chatting on my Win98 machine between two stacks
> with different addresses, 208.193.15.192 given to me
> by the ISP, and 127.0.0.1, the loopback address. In
> each stack I have a button with this script:
>
> on mouseUp
> put fld "sendIPfld" into vIP
> put fld "sendSocketFld" into vSocket
> put vIP&":"&vSocket into tDest
> open socket tDest
> put hostAddress(tDest)&return&peerAddress(tDest)
> into fld resultFld
> close socket tDest
> end mouseUp
>
> From each stack I get the same result -- the
> hostAddress and the peerAddress are the same, and that
> address is for the stack that I am connecting to, not
> the address for the stack with the button. Shouldn't
> they be different?
>
> I'm using two different port numbers -- one to go from
> the 208.193.15.192 address to the 127.0.0.1 address,
> and one to go back the other way. But I don't see how
> that could make any difference.
>
> Any help would be much appreciated. Michael Kann,
>
> [EMAIL PROTECTED]
Archives: http://www.mail-archive.com/metacard@lists.runrev.com/
Info: http://www.xworlds.com/metacard/mailinglist.htm
Please send bug reports to <[EMAIL PROTECTED]>, not this list.