Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Paradox setup assistance

Status
Not open for further replies.

lespaul

Programmer
Feb 4, 2002
7,083
US
I'm having some problems here! In the past I have always used a client/server setup with ODBC.

I'm now working on a project that I need to use local paradox tables and I'm confused. I have three tables that I need to populate from a text file. I have created all the tables in the DatabaseDesktop, tblVoterMain; tblVRContacts, tblVRAddress. However when I add a TTable component to the main form, it can't find the "database", now there is no database, there are four tables.

Now eventually, this will probably be changed to a client/server setup, but for now, I need local tables.

How do I set up the TTable or TQuery so that I use local tables?

Leslie
 
I think we are confused. Sorry if I'm wrong but it sounds like you are at the basics of Delphi...

What a few of us here will say, Use one TTable component for each Paradox table you have. Alter the parameters in the Object inspector so each TTable component has the table name eg Table name = tblVRcontacts; another TTable component has it's Table name = tblVRAddress and so on.

To let Delphi access any data from those tables, you have to put in Datasource components(same paletter but has 3 arrows shooting out. In most case, 4 TTable components set up, will have 4 Datasource components also.

Each datasource component is "attached" to one of those TTable components. Point one of those Datasource components to one of those TTables by assigning "table1" etc. The names of the Paradox tables will not be the same name of the TTable component eg: Table1 =tblVRcon.. Table2=tblVRadd... and so on - but you can rename them if you wish to.

As a default practice, right click on one of the TTable components and click on Fields editor... click that and an empty window should appear, right click over that and add all fields or choose the ones you need. Now each of those fields have their own set of properties which allows validation, field length and so on - Delphi tends to over-ride any restrictions you have set up with the paradox tables.

From there you can now put in eidt fields or whatever to complete your database program.

One last major point. IF you are not going to make the tables ACTIVE in runtime, then make them active in the development mode - this will give you live data as you design the rest of the system.

Cheers


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top