fbpx
× Visual Objects

Please use this forum to post questions about Visual Objects and Vulcan.NET

Char Set

More
1 year 7 months ago #1 by Juraj Halás
Char Set was created by Juraj Halás
I have a DBF file created in VO 2.6. When opening with OleDB connection in X# app, some characters will not be displayed correctly. In VO application, characters are displayed correctly on the same PC

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #2 by Robert van der Hulst
Replied by Robert van der Hulst on topic Char Set
Jura,

Which OLEDB provider are you using ?
Can you mail me an example file ?
Robert

XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #3 by Juraj Halás
Replied by Juraj Halás on topic Char Set
I using this connection string:
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source="+DBFDIR+";Extended Properties=dBASE IV;User ID=;Password=;"

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #4 by Robert van der Hulst
Replied by Robert van der Hulst on topic Char Set
Juraj,

Mosty likely the Jet Dbase IV driver is not properly recognizing the Ansi/OEM bit in the DBF file or not recognizing the codepage.
I need to see your file to give an answer to that and to help you to make this work.

Robert

XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #5 by Juraj Halás
Replied by Juraj Halás on topic Char Set
I sent a DBF file on the mail This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #6 by Robert van der Hulst
Replied by Robert van der Hulst on topic Char Set
Juarj,

Your database is created on a Central/Eastern European windows computer. This is visible when you look at byte 29 in the file. It has the value 0xC8.
That corresponds to the Codepage 1250.

https://msdn.microsoft.com/en-us/library/aa975345(v=vs.71).aspx

You need to tell the Jet driver to use a locale that matches that codepage too by adding the string "Locale Identifier=nnnn;" to your connection string.

You need to select a locale that has codepage 1250.

See http://www.science.co.il/language/Locale-codes.php

For example 1045 (Polish), 1029 (Czech) or 1051 (Slovak).

That should fix the problem.

Robert

XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #7 by Juraj Halás
Replied by Juraj Halás on topic Char Set
Rober,

I used more versions connstring:
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source="+DBFFullNaz+";Extended Properties=dBASE IV;User ID=;Password=;Locale Identifier=1250"
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source="+DBFFullNaz+";Extended Properties=dBASE IV;User ID=;Password=;Locale Identifier=1252"
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source="+DBFFullNaz+";Extended Properties=dBASE IV;User ID=;Password=;Locale Identifier=1051"
But the problem has not fixed.

Juraj
Attachments:

Please Log in or Create an account to join the conversation.

More
1 year 7 months ago #8 by Robert van der Hulst
Replied by Robert van der Hulst on topic Char Set
Juraj,

You need to give me more information.
Do you see any difference when you set the locale ?
And as far as I know you do not give the locale the codepage but the country id. So not 1250 or 1252 but 1051.

How are you checking the text? With the console window or on a UI window. Is that a VO GUI window (Ansi) or a Winforms window (Unicode).

And what is the active Ansi codepage on your computer ?

Can you create a small example of what you are doing.


Robert

XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.