F
Frank M
I am writing an application with a dataload class. The
development is done in Windows XP, and on the development
Pc I can do a dataload and export without any problems if
I use System.Text.UTF8Encoding on the datastream for
writing. The datafile is still in windows standard
codepage, also for the special chars for Scandinavia
(e.g. æ,ø,å).
However, when I transfer my application to a Pc running
Windows 2000, the special chars are converted to
gibberish (the lower ASCII chars are handled just fine).
Now, to handle it I have then tried to run the export
with UTF7Encoding, ASCIIEncoding and finally
UnicodeEncoding - none of them works for the special
chars and some not at all. Is there any other encoding I
should use?
I have also thought that the problem might not be in the
export but in the loading of the data (i.e. is the
datafile read correctly). For the dataload I use the
OleDbDatareader. As far as I can see, the OleDBDataReader
or OleDbConnection, does not include a property to
control Encoding for the load. I guess it could also be
something that is set as part of the the connection
string and not a regular property. But on Windows XP
where I develop and test I only need to control the
encoding for the StreamWriter and not for the load.
Help will be much appreciated.
With kind regards,
Frank M.
development is done in Windows XP, and on the development
Pc I can do a dataload and export without any problems if
I use System.Text.UTF8Encoding on the datastream for
writing. The datafile is still in windows standard
codepage, also for the special chars for Scandinavia
(e.g. æ,ø,å).
However, when I transfer my application to a Pc running
Windows 2000, the special chars are converted to
gibberish (the lower ASCII chars are handled just fine).
Now, to handle it I have then tried to run the export
with UTF7Encoding, ASCIIEncoding and finally
UnicodeEncoding - none of them works for the special
chars and some not at all. Is there any other encoding I
should use?
I have also thought that the problem might not be in the
export but in the loading of the data (i.e. is the
datafile read correctly). For the dataload I use the
OleDbDatareader. As far as I can see, the OleDBDataReader
or OleDbConnection, does not include a property to
control Encoding for the load. I guess it could also be
something that is set as part of the the connection
string and not a regular property. But on Windows XP
where I develop and test I only need to control the
encoding for the StreamWriter and not for the load.
Help will be much appreciated.
With kind regards,
Frank M.