NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Developers v
« Previous 1 … 76 77 78 79 80 … 93 Next »
webstream and funny chars

 
  • 0 Vote(s) - 0 Average
webstream and funny chars
reven
Offline

Posting Freak

Posts: 5,782
Threads: 396
Joined: Sep 2004
#1
2005-02-26, 10:37 AM
anyone know how to keep the funny characters from a webstream? eg ö,ü,ß

im using this code at the moment
<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">WebRequest objRequest = WebRequest.Create(strURL);

//The WebResponse object gets the Request's response (the HTML)
WebResponse objResponse = objRequest.GetResponse();

//Now dump the contents of our HTML in the Response object to a
//Stream reader
StreamReader oSR = new StreamReader(objResponse.GetResponseStream());

//And dump the StreamReader into a string...
m_strSite = oSR.ReadToEnd();[/QUOTE]
and if i print out m_strSite all of the characters are missing.
reven
Offline

Posting Freak

Posts: 5,782
Threads: 396
Joined: Sep 2004
#2
2005-02-26, 11:03 AM
nm i got it to work using
<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">StreamReader oSR = new StreamReader(objResponse.GetResponseStream(),System.Text.Encoding.GetEncoding(1252));[/QUOTE]

now gets all the shiny happy characters!
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)



  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode