Click to See Complete Forum and Search --> : MSComm1 bug recieving sequence


help chris
February 2nd, 2000, 09:26 AM
I have been trying to recieve a data stream through the serial port with MicroSofts Comm control. Using VB6 (with vs6 sp3 installed) I'm pulling everything directly off the serial port with a simple line of:

memBuf = memBuf & MSComm1.Input

however, MSComm1 drops a byte when it recieves the following:

0D 0A 0D

which is 13,10,13 the equivelant of carriage return, linefeed, carriage return.

Anyway, it keeps the two 0D and drops the 0A. The 0A never gets placed into the mem buffer.

memBuf is setup like: Dim memBuf
I've also tried different things like Dim memBuf as Variant (string, byte, int etc...)

It seems to me that the comm control just eats the 0A anytime it recieves it between two 0D's

This is very bad obviously, and was wondering if anyone knows of a work around/ patch?

btw, i'm transmitting a binary file, so gotta have all those bytes...

thanks