how to convert ASCII stram to Unicode string

  • Thread starter Thread starter Jay
  • Start date Start date
J

Jay

Hi,
I am passing a char array through infrared socket.In .net compact
framework I am using IrDAClient class to get the stream.This stream
I'll read in byte array. I want to convert the ASCII byte array to
Unicode string. How to do that?

Thanks
Jayshri
 
You can use the System.Encoding class. It supports ASCII, Unicode, UTF7
and UTF8.


--
I hope this helps

--
Norman Rericha
Senior Software Engineer
Applied Data Systems
www.applieddata.net
An ISO 9001:2000 Registered Company
Microsoft WEP Gold-level Member
 
To expand slightly:
string sAscii = Encoding.ASCII.GetString(arrBytes, 0, numBytes);
 
Back
Top