Dear friends

I want to develope a single form which can perform as local and remote host simultaneously, is it possible if yes then please tell me how. Basically what i am doing, that i set winsock.localport = 15151 and winsock.listen on form load event.

when any user want to send message to any other user i wrote these code

if user = 'aa' then
winsock.remotehost = "192.168.0.2"
if user = "bb" then
winsock.remotehost = "192.168.0.3"
endif
winsock.remoteport = 15151
winsock.connect

it is not working , where i am mistaking