Usually, there is no such thing as a double-byte character in .NET -- it uses UTF-16 Unicode, in which *every* character is expressed by two bytes.
However, if you're reading a file or stream that is coming in as a multi-byte character set (something like Shift-JIS or UTF-8), then you'll have to write code to convert it to UTF-16, or use one of the built-in Convert methods (in the case of UTF-8).
Thanks.
I think I did't write clearly.
I mean, for example, I need to extract all double byte character (something like Shift-JIS or UTF-8) but not alphabets from a file
You'll need to learn more about the particular multi-byte encoding that you'll be receiving -- they all do it differently.
I haven't done any work with Shift-JIS, but in UTF-8, the first byte in a multi-byte sequence are always "11vvvvvv", with subsequent bytes "10vvvvvv". Take a look at:
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.