Devart Forum Index

The time now is Thu 09 Sep 2010 04:02

TUniConnection in Delphi 2009

 
Post new topic   Reply to topic    Devart Forum Index -> Universal Data Access Components
View previous topic :: View next topic  
Author Message
Syncmas



Joined: 22 Jul 2010
Posts: 1

PostPosted: Thu 22 Jul 2010 18:59    Post subject: TUniConnection in Delphi 2009 Reply with quote

We are currently looking at your product for inclusion in one of our projects and are encountering a problem that I am unable to solve.

Delphi 2009 and SQLite Database 3.6.23

If I drop a UniConnection on a data module, point it to my SQLite database, set my ClientLibrary and "connect" in design mode, everything appears fine in the project.

If I then disconnect during design time and instead try to connect using that same component with variables, the component says it is connected however it then finds none of my tables.

This is the code I am using to utilize that connection, can someone please tell me what i am missing....

if dmSLICData.dbCommon.Connected = false then
begin
dmSLICData.dbCommon.ProviderName := 'SQLite';
dmSLICdata.dbCommon.Database := CommonDBPath;
dmSLICData.dbCommon.SpecificOptions.Values['ClientLibrary'] := 'c:\NextGen\sqlite3.dll';
dmSLICdata.dbCommon.Connect;
end;


Thanks for any help anyone can provide!

Scott
Back to top
View user's profile Send private message
bork
Devart Team


Joined: 12 Mar 2010
Posts: 467

PostPosted: Mon 26 Jul 2010 09:49    Post subject: Reply with quote

Hello

In the design-time and in the run-time the default application folder is different. Maybe in the run-time and in the design-time you open different databases. So try to set full path to your database, for example, like this:
dmSLICdata.dbCommon.Database := ''c:\NextGen\database.s3db';
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Devart Forum Index -> Universal Data Access Components All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum