I am in the process of converting some c# code to that of VB.NET…I am running into error at the following
C#
if (bytes[i - 1] == ' ')
{
returnValue.Append("=20");
}
else if (bytes[i - 1] == '\t')
{
returnValue.Append("=09");
}
VB.NET
If bytes(i - 1) = " "C Then <==error Operator "=" is not defined for types 'Byte' and 'Char'
returnValue.Append("=20")
ElseIf bytes(i - 1) = ControlChars.Tab Then <==error Operator "=" is not defined for types 'Byte' and 'Char'
returnValue.Append("=09")
End If
I believe the actual problems lies with the initial comparison. You are trying to compare a
byteto achar. Try converting thebyteto acharfirst.