C
Claire
I'm writing strings to an embedded console that only supports Extended ASCII
Code Page 437.
The strings are stored in a lookup table in a database .
My original code is as follows which writes to a memory stream:
System.Text.ASCIIEncoding Encoding = new System.Text.ASCIIEncoding();
MachineIDs.Write(Encoding.GetBytes(EquipmentRecord.LabelID));
MachineIDs.Write('\0');
MachineIDs.Write(Encoding.GetBytes(EquipmentRecord.EnglishDesc));
MachineIDs.Write('\0');
MachineIDs.Write(Encoding.GetBytes(EquipmentRecord.GermanDesc));
MachineIDs.Write('\0');
The above code isn't writing using the correct code page.The german 'ü' char
0xFC is being written as char 0x3F using the above.
How do I specify a code page please?
thanks
Claire
Code Page 437.
The strings are stored in a lookup table in a database .
My original code is as follows which writes to a memory stream:
System.Text.ASCIIEncoding Encoding = new System.Text.ASCIIEncoding();
MachineIDs.Write(Encoding.GetBytes(EquipmentRecord.LabelID));
MachineIDs.Write('\0');
MachineIDs.Write(Encoding.GetBytes(EquipmentRecord.EnglishDesc));
MachineIDs.Write('\0');
MachineIDs.Write(Encoding.GetBytes(EquipmentRecord.GermanDesc));
MachineIDs.Write('\0');
The above code isn't writing using the correct code page.The german 'ü' char
0xFC is being written as char 0x3F using the above.
How do I specify a code page please?
thanks
Claire