-
A tricky one :o)
Hi:
I'm a newbie Visual C ++ programmer, and I'm trying to do a Simple chat using winsock.ocx, I have already done one in VB5 but now I would like to do it in VC.
Mainly, i'm having problems with .Connect metod, I don't understand what Const VARIANT &RemoteHost and Const VARIANT &RemotePort means.
PD: I have a chat example but it uses API and i would like to do it just using winsock.ocx.
Thanks and I hope you help.:D
-
Wait a moment.
First, OCX is evil. ActiveX in general is evil, but even more so if you use it in C++. Don't if you can avoid it. The API is much faster and easier to use as you don't have to mess around with VARIANTs and SAFEARRAYs and BSTRs, all those evil VB data types.
Second, I how much of a newbie are you? Unless you know the language you probably shouldn't go as far as using the API, it can get very confusing.
-
If you use the winsock OCX, which was intended for VB (and AFAIK, made in VB), that sort of defeats the purpose of programming in VC++.