serial communication using MS Comm Control v.6

i am using MS Comm control to communicate with the serial port using visual c++6. i am having problems in sending data.

here is the rough code i am using. ( just to give an idea )

com1.SetComPort(1); // assuming com1 is the object of comm control
com1.SetSettings("9600,N,8,1");
com1.SetPortOpen(true);

VARIANT var;
.
.
.
com1.SetOutput(var);
.
.
.
com1.SetPortOpen(false);

the problem is, I don't know what VARIANT is and how to use it with comm control, i have tried MSDN but it didn't help me much. please let me know the exact process of sending data to com port ( comm component must be used ).

thanks
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories