Encoding
-
I am using HttpWebRequest and Response classes in order to query a third party database. But the problem is , encoding is in ISO_8859 format and couldnt retrieve some characters ..as I looked so far in the method of streamReader class , only ASCII , utf 7-8 and a few more are available..But I want to encode streamReader with ISO-8859 So far I am using the following method. sr = new StreamReader(resp.GetResponseStream(), System.Text.Encoding.UTF8); .. How could I achieve this? Any suggestions or piece of code will be welcomed:) Thanks in advance.
-
I am using HttpWebRequest and Response classes in order to query a third party database. But the problem is , encoding is in ISO_8859 format and couldnt retrieve some characters ..as I looked so far in the method of streamReader class , only ASCII , utf 7-8 and a few more are available..But I want to encode streamReader with ISO-8859 So far I am using the following method. sr = new StreamReader(resp.GetResponseStream(), System.Text.Encoding.UTF8); .. How could I achieve this? Any suggestions or piece of code will be welcomed:) Thanks in advance.
There's a static
System.Text.Encoding.GetEncoding()
method you can use to get a certain encoding with a given name. Regards, mav