Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 ASP.NET
 Encoding problem after Win 2003 SP1

Author  Topic 

BigMeat
Yak Posting Veteran

56 Posts

Posted - 2005-05-01 : 15:19:46
Hi,

I have web app that has the been encoded to the following:

<globalization fileEncoding="iso-8859-1" requestEncoding="iso-8859-1" responseEncoding="iso-8859-1" />

This was done to get round a problem that I had with adding a UK £ sign to my database. I changed it from the standard

<globalization requestEncoding="utf-8" responseEncoding="utf-8" />

However after I installed Windows 2003 SP1, I have noticed that I have now encountered a encoding problem, when using is-8859-1. If I have a label and I pass it a string that contains apostrophes it turns all the apostrophes into ? (question marks). It just seems really odd

If I change the encoding back to utf-8 the problem is resolved, but then I inherit the pound sign problem. Has anybody else experienced this problem after upgrading their 2003 server to SP1?

My code is really simple
Dim str As String = "We’re sorry but we can’t find anything about at the moment. "
Label1.Text = str

The output of the above is:
We?re sorry but we can?t find anything about at the moment.

It works prefectly fine on my Development machine when I use iso-8859-1 which is a Win XP SP2 box, but the problem just seems to be when I transfer the files on to my web server which is a Win 2003 SP1, I have managed to work out that it worked perfectly fine before SP1

Any help would be much appreciated, thanks in advance

   

- Advertisement -