From VB to Csharp

  • Thread starter Thread starter cfyam
  • Start date Start date
C

cfyam

How can I convert the VB 6 statement below to C#?
MSComm1.Output = Chr(&H1B) + "I" & Chr(13)
 
cfyam said:
How can I convert the VB 6 statement below to C#?
MSComm1.Output = Chr(&H1B) + "I" & Chr(13)

MSComm1.Output = Convert.ToChar(27) + "I" + Convert.ToChar(13);

That works... might not be the best way to do it, though. You could also
do it this way:

MSComm1.Output = (char)27 + "I" + (char)13;

Lowell
 
Back
Top