Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Datenbanken (https://www.delphipraxis.net/15-datenbanken/)
-   -   Delphi EAccessViolation wenn AdsConnection in DataModul (https://www.delphipraxis.net/133699-eaccessviolation-wenn-adsconnection-datamodul.html)

PASST 7. Mai 2009 06:48

Datenbank: ADS • Version: 9.10 • Zugriff über: Advantage Komponenten

EAccessViolation wenn AdsConnection in DataModul
 
Hallo allerseits,

Delphi 7 + ADS Datenbank 9.10

Ich kämpfe gerade mit einem sehr lästigen Problem.

Ich möchte alle Datenbankkomponenten in ein eigenes DataModul/eigene DataUnit platzieren. Wenn ich das so mache, erhalte ich beim Aufruf der AdsConnection eine EAccessViolation. Platziere ich die ADS-DBkomponenten direkt in meinem Programmformular, so funktioniert alles tadellos.

Hat jemand eine Idee, was da los sein könnte?

gruß
Peter

P.S.: Das ist ein Crossposting zum Entwicklerforum Datenbanken.

dataspider 7. Mai 2009 06:52

Re: EAccessViolation wenn AdsConnection in DataModul
 
Sorry,

klingt sehr nach: DataModule nicht erzeugt...


Frank

Chemiker 7. Mai 2009 07:02

Re: EAccessViolation wenn AdsConnection in DataModul
 
Hallo PASST,

das Datenmodul in der Project-Datei als erstes aufrufen.

Delphi-Quellcode:
Application.CreateForm(TDM, DM);
Application.CreateForm(TfrmSPSDAPHauptMenue, frmSPSDAPHauptMenue);
Bis bald Chemiker

Bernhard Geyer 7. Mai 2009 07:17

Re: EAccessViolation wenn AdsConnection in DataModul
 
Crosspost beim Entwickler-Forum

PASST 7. Mai 2009 07:26

Re: EAccessViolation wenn AdsConnection in DataModul
 
Es lag tatsächlich an der Erstellreihenfolge der einzelnen Formulare.

Ich hatte das zwar gestern schon diesen Verdacht, dann aber nicht genau hingeschaut, wo ich denn was ändern muss. Nu ist es klar!


Alle Zeitangaben in WEZ +1. Es ist jetzt 18:39 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz