J Jon Skeet [C# MVP] Jan 9, 2008 #2 Arne Garvander said: How do I convert a char to a byte, if the char is not an ASCII char? Click to expand... That entirely depends on the encoding.
Arne Garvander said: How do I convert a char to a byte, if the char is not an ASCII char? Click to expand... That entirely depends on the encoding.
C Cowboy \(Gregory A. Beamer\) Jan 11, 2008 #3 If it is outside of the first 256 characters, you cannot turn it into a byte. You can make it binary, however, and turn it into a string of bytes by using encoding. Example: http://www.koders.com/csharp/fid9EB93DD6509F335D388AFC03B92E2FD1EF04C64B.aspx?s=mdef:insert -- Gregory A. Beamer MVP, MCP: +I, SE, SD, DBA ************************************************* | Think outside the box! | *************************************************
If it is outside of the first 256 characters, you cannot turn it into a byte. You can make it binary, however, and turn it into a string of bytes by using encoding. Example: http://www.koders.com/csharp/fid9EB93DD6509F335D388AFC03B92E2FD1EF04C64B.aspx?s=mdef:insert -- Gregory A. Beamer MVP, MCP: +I, SE, SD, DBA ************************************************* | Think outside the box! | *************************************************