|
Home > Archive > Getting Started with dBASE > February 2006 > characters codepage
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
characters codepage
|
|
|
| Hi,
when reading my MSDOS DB4 data written under codepage 437 to Windows, some characters are replace with comas or changed. How can I convert the data to the standard Windows codepage, as I presume that the codepage difference is the source of the trouble ?
Thank you
Dominique
| |
| Ken Mayer [dBVIPS] 2006-01-30, 9:24 am |
| DLIT wrote:
> Hi,
> when reading my MSDOS DB4 data written under codepage 437 to Windows, some characters are replace with comas or changed. How can I convert the data to the standard Windows codepage, as I presume that the codepage difference is the source of the trouble
?
You may need to compare an ASCII character chart to an ANSI character
chart. Not all characters are in the same places ...
(There are places on the net where you can find both charts ...)
Ken
--
/(Opinions expressed are purely my own, not those of dataBased
Intelligence, Inc.)/
*Ken Mayer* [dBVIPS]
/Golden Stag Productions/
dBASE at goldenstag dot net
http://www.goldenstag.net/dbase/dBASEBook.htm
http://www.goldenstag.net/GSP
http://www.goldenstag.net/dbase
| |
| John Marshall 2006-01-30, 11:23 am |
|
Try setting the ldriver in the PLUS.ini under
the & #91;CommandSettings]
as below:
& #91;CommandSettings]
ldriver = DB437US0
Also, I have found that what the system uses and what you see in a command/browse window are not the same. These need to be set to fonts that support the characters you desire. In the example below, these fonts show and support the IBM Extended Characte
r Set.
[CommandWindow]
ResultsPaneFont=Cour
ier New, 10
InputPaneFont=Courie
r New, 10
Hope this helps.
JM
DLIT Wrote:
> Hi,
> when reading my MSDOS DB4 data written under codepage 437 to Windows, some characters are replace with comas or changed. How can I convert the data to the standard Windows codepage, as I presume that the codepage difference is the source of the trouble
?
> Thank you
> Dominique
>
| |
| Roland Wingerter 2006-01-31, 7:23 am |
| Hi Dominique,
"DLIT" wrote
> when reading my MSDOS DB4 data written under codepage 437 to Windows, some
> characters are replace with comas or changed. How can I convert the data
> to the standard Windows codepage, as I presume that the codepage
> difference is the source of the trouble ?
-------
Normally it should not be necessary to convert the data. dBASE should
display the data correctly using the table's language driver, even when its
different from the global language driver.
Just to be sure, check the language driver and character set.
// Global language driver and charset
close data
? ldriver() // e.g. "DBWINWE0"
? charset() // e.g. "WIN1252"
// Table language driver and charset
use <tablename>
? ldriver() // ?
? charset() // ?
Maybe the language driver is not what you expect? Regardless of the language
driver, see if it helps to convert character fields with ANSI() or OEM().
Don't forget to make a backup first!
Roland
| |
|
| Ken Mayer [dBVIPS] Wrote:
> DLIT wrote:
e ?[color=darkred]
>
> You may need to compare an ASCII character chart to an ANSI character
> chart. Not all characters are in the same places ...
>
> (There are places on the net where you can find both charts ...)
>
> Ken
>
> --
> /(Opinions expressed are purely my own, not those of dataBased
> Intelligence, Inc.)/
>
> *Ken Mayer* [dBVIPS]
> /Golden Stag Productions/
> dBASE at goldenstag dot net
> http://www.goldenstag.net/dbase/dBASEBook.htm
> http://www.goldenstag.net/GSP
> http://www.goldenstag.net/dbase
This reply seems to fit my question. I'm checking on the Web some ASCII->ANSI converters and found one open source code that seems to solve the problem.
Thanks for your help
Dominique
| |
|
| Thank you for your reply but it fits to another question. Ken is right I think with the ASCII/ANSI conversion matter
Dominique
John Marshall Wrote:
>
> Try setting the ldriver in the PLUS.ini under
> the & #91;CommandSettings]
as below:
>
>
> & #91;CommandSettings]
> ldriver = DB437US0
>
> Also, I have found that what the system uses and what you see in a command/browse window are not the same. These need to be set to fonts that support the characters you desire. In the example below, these fonts show and support the IBM Extended Charac
ter Set.
>
>
> [CommandWindow]
>
> ResultsPaneFont=Cour
ier New, 10
> InputPaneFont=Courie
r New, 10
>
>
> Hope this helps.
>
> JM
>
>
> DLIT Wrote:
>
e ?[color=darkred]
>
| |
|
| Hi Roland
Danke für Ihre Antwort. But Ken's reply fits my problem with the ASCII/ANSI matter. My problem concerns the migration of my DB4 DOS data. I meet the problem on the same computer, therefore with the same pagecode.
Dominique
Roland Wingerter Wrote:
> Hi Dominique,
>
> "DLIT" wrote
> -------
> Normally it should not be necessary to convert the data. dBASE should
> display the data correctly using the table's language driver, even when its
> different from the global language driver.
>
> Just to be sure, check the language driver and character set.
>
> // Global language driver and charset
> close data
> ? ldriver() // e.g. "DBWINWE0"
> ? charset() // e.g. "WIN1252"
>
> // Table language driver and charset
> use <tablename>
> ? ldriver() // ?
> ? charset() // ?
>
> Maybe the language driver is not what you expect? Regardless of the language
> driver, see if it helps to convert character fields with ANSI() or OEM().
> Don't forget to make a backup first!
>
> Roland
>
>
>
>
>
>
>
>
>
| |
| Roland Wingerter 2006-02-02, 3:23 am |
| "DLIT" wrote
>
> Danke für Ihre Antwort. But Ken's reply fits my problem with the
> ASCII/ANSI matter. My problem concerns the migration of my DB4 DOS data. I
> meet the problem on the same computer, therefore with the same pagecode.
------
You don't need to use an external tool, you can use ANSI() to convert
character data from ASCII to ANSI. Check the OLH on ANSI().
Roland
| |
|
| Yes I found that in the meantime, but what I did not yet experimented is whether this command can be applied to a full file or only character per character.
Dominique
Roland Wingerter Wrote:
> "DLIT" wrote
> ------
> You don't need to use an external tool, you can use ANSI() to convert
> character data from ASCII to ANSI. Check the OLH on ANSI().
>
> Roland
>
>
>
| |
| Roland Wingerter 2006-02-02, 7:23 am |
| "DLIT" wrote
> Yes I found that in the meantime, but what I did not yet experimented is
> whether this command can be applied to a full file or only character per
> character.
------
You have to convert each char field, e.g.
use fish
replace all name with ansi(name), species with ansi(species)
Roland
| |
|
| Noted. Thanks, although I noticed that the problem only occured on txt data such as prg, whilst dbf data seem to be automatically converted, when read under Windows.
Moreover the problem concerns essentially only the few accentuated voyels
Dominique
Roland Wingerter Wrote:
> "DLIT" wrote
> ------
> You have to convert each char field, e.g.
>
> use fish
> replace all name with ansi(name), species with ansi(species)
>
> Roland
>
>
>
| |
| Roland Wingerter 2006-02-03, 11:23 am |
| DLIT wrote
> Noted. Thanks, although I noticed that the problem only occured on txt
> data such as prg, whilst dbf data seem to be automatically converted, when
> read under Windows.
------
OK, fine. For the source code editor, there is a setting. Open the source
code editor, then choose menu option Properties > Source Editor Properties.
Roland
| |
| John Marshall 2006-02-03, 11:23 am |
| Roland is Correct, and such changes are written to your plus.ini. You need to make sure that the .ini file settings are specifying a font that supports the characters that you are looking for for both the editor AND the command window. I use the extende
d graphics characters and needed to set my .ini to the following:
[CommandWindow]
ResultsPaneFont=Cour
ier New, 10
InputPaneFont=Courie
r New, 10
JM
DLIT Wrote:
> Noted. Thanks, although I noticed that the problem only occured on txt data such as prg, whilst dbf data seem to be automatically converted, when read under Windows.
> Moreover the problem concerns essentially only the few accentuated voyels
> Dominique
>
>
> Roland Wingerter Wrote:
>
>
|
|
|
|
|