Chr$
just converts an integer representing a code point to the actual
char
the code point represents.
MSComm1.Output = "B" + Convert.ToChar(IOValA);
But you have to be careful. If the current thread is MBCS (like Unicode) you may get a larger code point than the PIC allows. You could check that IOVal* is < 128 which will be fine in most cases as simpel code. But to really be sure and robust, see the
ASCIIEncoding
class.