0

I have an ASP.NET web app running on a W2003 Server normally. The app copies a .txt file from a remote machine to the server. Afterwards the process rename the .txt file to .xml.

The problem has come when I tried to install the web in a W2008 R2 Server. Suddenly every latin character included in the .txt is not showing properly.

.txt -><TO>COMPROBACION CAMPAÑA</TO>
.xml -><TO>COMPROBACION CAMPA�A</TO>

My ASP.NET Globalization is set to False.

The Windows Server Language is Spanish in both servers (2003 and 2008).

Could anyone tell me what else can be?

4

1 回答 1

0

最后我发现问题是读取远程主机文件。

老方法

Dim stream_reader As New StreamReader(Fich, "ISO-8851", True)) 

新方法

Dim stream_reader As New StreamReader(Fich, Encoding.Default, True))

现在 xml 文件保留原始编码。尼皮是对的。

谢谢。

于 2012-10-31T15:01:37.090 回答