Converting ASCII Text file to Unicode
Hi,
The problem i am having is that i have to process CSV files into the database. My CSV files are in ASCII format as provided by customer. These files can contain german characters so therefor i need to save these in unicode format so that i can read them and update in SQLServer.
Currently what i do is that i open the CSV file and save it in Unicode format manually and all processing is done alright. What i have to do is to write an application which will process these files automatically. So want the saving to be done by the application.
I am using C#.Net as my programming language.
I have searched the web and different forums for this. The solution that most of the forums have provided is to use StreamReader and StreamWriter classes and use Encoding.unicode or Encoding.UTF-8. The file is saved alright but german characters are still not been converted to unicode.
I have tried almost all ways i found on internet for this purpose to try saving file in unicode but havent succeeded yet.
Will any body tell me that what mistake i am making that german characters are not been converted to unicode.
Thanks
|