Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: database connexion bindsourcedb


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 1 - Last Post: Oct 31, 2015 6:45 AM Last Post By: El Moataz Billa...
El Moataz Billa...

Posts: 4
Registered: 5/4/12
database connexion bindsourcedb  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 31, 2015 5:40 AM
Hello.

in order to show table contents, i am using adoquery connected to stirnggrid by BindSourceDB1 and edit to filter data when typing,
in standard mode (adoquery has connectionsting and is activated before debugging) every think work nice and correct.

the problem is that i should use an inifile to connect database,
the connection is done when formecreate and work well when calling any query by code,
except my stringgrid didn't show any records.

i have tried to connect my adoquery to my addoconnection and activate it using code.
onbeforopen for adoquery is executed befor the formecreate that contain it.

So i need to know when is the good moment to set adoquery.connection proprieties to adoconnection and activate adoquery.

thanks a lot
El Moataz Billa...

Posts: 4
Registered: 5/4/12
Re: database connexion bindsourcedb  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Oct 31, 2015 6:45 AM   in response to: El Moataz Billa... in response to: El Moataz Billa...
Solution founded :

adoconnection.afterconnect
begin
adoquery.Active:=true;
end;
that's all.
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02