Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problems with MSWINSCK.OCX WinSock control
Message
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00402471
Message ID:
00403353
Views:
10
<>

I am calling the connect method. Here is my code:

thisform.olecontrol1.remotehost = "192.0.0.50"
thisform.olecontrol1.remoteport = 1070
thisform.olecontrol1.connect

I looked in the help and didn't see anything about parameters? What parameters do I have to pass?

Thanks for you help!

Don Knoup
dknoup@unitydc.com
Unique Solutions


>>I'm trying to use the winsock control on a VFP form. Works fine in VB but I can't seem to make it work in VFP.
>>
>>The "server" I'm trying to connect to is an ethernet data collection terminal. It's IP address is 192.0.0.50 and the port address is 1070. I use TCP to connect to it (not UDP).
>>
>>In VB if I put the winsock control on a form. I put the following code in a command button (click):
>>
>>winsock1.remotehost = "192.0.0.50"
>>winsock1.remoteport = 1070
>>winsock1.connect command
>>
>>... and I'm connected to the data collection terminal.
>>
>>In VFP if I put the winsock control on a form. I put the following code in a command button (click):
>>
>>thisform.olecontrol1.remotehost = "192.0.0.50"
>>thisform.olecontrol1.remoteport = 1070
>>thisform.olecontrol1.connect
>>
>>... it doesn't connect?
>>
>>Does anyone know what the difference is between this control in VB versus VFP??
>>
>>Thanks,
>>Don Knoup
>>dknoup@unitydc.com
>>Unique Solutions
>
>In VFP you have to do the connect method. Look in the help and you can see that you have to pass two parameters to get it work in VFP.
Don Knoup
don.knoup@ticomix.com
Ticomix, Inc.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform