Board index » delphi » Shared database between Windows and DOS application

Shared database between Windows and DOS application

Hi,

I had a look at Kyle Corde's web-site for info on a FoxPro compatible
databasedriver that will do automatic OEM to ANSI conversion when reading
data from an OEM database and the opposit conversion when writing data to an
OEM database. Unfortunately I was unable to determine if any of the
databasedrivers listed could do this.

The reason I need this is that I'm writing an application in Delphi 4 that
must read and write data in an OEM FoxPro database simultaniously with a
Clipper application.

Any other ideas to accomplish this are most welcome.

Regards,

Erik F. Andersen

 

Re:Shared database between Windows and DOS application


Erik F. Andersen (e...@ascott.dk) wrote:
: Hi,

: I had a look at Kyle Corde's web-site for info on a FoxPro compatible
: databasedriver that will do automatic OEM to ANSI conversion when reading
: data from an OEM database and the opposit conversion when writing data to an
: OEM database. Unfortunately I was unable to determine if any of the
: databasedrivers listed could do this.

so why don't you write a ttable descendant and overwrite the post method
with your own one (you have to change the field.asstring() function too)?

in you own post method, you first convert any string
field contents from ansi to oem (if needed, but it's rather easy to detect
wether a string is allready OEM).

Stefan Gebers

--
-----------------------------------------------------
geb...@studserv.stud.uni-hannover.de

Toleranz ist das unbehagliche Gefuehl,
der Andere koennte am Ende vielleicht
doch recht haben.
                        Robert Forst

Re:Shared database between Windows and DOS application


Hi,

the problem is much more complicated than that. The big problem is _not_ to
corrupt the indexes when updating records from Delphi. The sorting order
must not depent on any ANSI setting, it should be nation specific (danish in
my case), so that AnsiToOem('?') < AnsiToOem('?') < AnsiToOem('?') <
AnsiToOem('?') < AnsiToOem('?') < AnsiToOem('?'). The sorting of these
special danish characters must be the same in Delphi (Windows app) and in
Clipper (DOS app). In Clipper things work fine as long as I tell Clipper
that it should use danish sorting. I have tested this using CodeBase 6.4 and
it does not update the indexes correct.

Regards,

Erik F. Andersen

Stefan Gebers skrev i meddelelsen
<7n9sav$jp...@newsserver.rrzn.uni-hannover.de>...

Quote
>Erik F. Andersen (e...@ascott.dk) wrote:
>: Hi,

>: I had a look at Kyle Corde's web-site for info on a FoxPro compatible
>: databasedriver that will do automatic OEM to ANSI conversion when reading
>: data from an OEM database and the opposit conversion when writing data to
an
>: OEM database. Unfortunately I was unable to determine if any of the
>: databasedrivers listed could do this.

>so why don't you write a ttable descendant and overwrite the post method
>with your own one (you have to change the field.asstring() function too)?

>in you own post method, you first convert any string
>field contents from ansi to oem (if needed, but it's rather easy to detect
>wether a string is allready OEM).

>Stefan Gebers

>--
>-----------------------------------------------------
>geb...@studserv.stud.uni-hannover.de

>Toleranz ist das unbehagliche Gefuehl,
>der Andere koennte am Ende vielleicht
>doch recht haben.
> Robert Forst

Re:Shared database between Windows and DOS application


In article <7n78v2$b4...@gloup.linuxfr.org>,
  "Erik F. Andersen" <e...@ascott.dk> wrote:

Quote
> Hi,

> I had a look at Kyle Corde's web-site for info on a FoxPro compatible
> databasedriver that will do automatic OEM to ANSI conversion when
reading
> data from an OEM database and the opposit conversion when writing data
to an
> OEM database. Unfortunately I was unable to determine if any of the
> databasedrivers listed could do this.

> The reason I need this is that I'm writing an application in Delphi 4
that
> must read and write data in an OEM FoxPro database simultaniously with
a
> Clipper application.

> Any other ideas to accomplish this are most welcome.

> Regards,

> Erik F. Andersen

Hi Erik,

I use Halcyon database engine v6 to read Clipper databases with comix
RDD indexes (CDX Foxpro like).

The Delphi program reads and writes (OEM->ANSI , ANSI->OEM ) with no
problem record fields and index data. I use the spanish character set
(,,,,,?,?) and I have no trouble with the conversion issues.

But I am not sure if this works also with the danish character set.

Anyway Halcyon comes with the full source code ;)

You can post your question to the Halcyon email list.

To post to the list, email halc...@yabin.com

To join, email halcyon-requ...@yabin.com with SUBSCRIBE as the only
message

Best wishes.

Teo Fonrouge

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.

Other Threads