Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using multiple databases within application
Message
From
14/02/2000 16:28:01
Jerry Tovar
Dana Corporation Dana It
Maumee, Ohio, United States
 
 
To
14/02/2000 14:46:17
Michael Dougherty
Progressive Business Publications
Malvern, Pennsylvania, United States
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00331825
Message ID:
00331930
Views:
27
>
>The DBCs directory would contain all the DBC files for the sake of an easy pick-list. the userN directory contains the similarly named tables, which the DBC would keep straight for you. (ex: Use Table1 - automatically opens the table1 file from the location registered in the User1.dbc)
>
>Do you intend to have multiple (same-name) tables open simultaneously or several (same-name) tables that open serially/one .DBC at a time?

Michael,

Thanks for your reply.

My DBC is always the same name, Acme.dbc. This DBC always contains the same tables, cust.dbf, invoice.dbf, ect...

What I plan on doing is:
1. Allow the users to create a new DBC and tables in a desired directory.
2. Have a free table that contains the full path to each DBC.
3. Let the user select a DBC from the free table.
4. Set some global properties to store the path to the desired DBC.
5. Close any opened DBCs and DBFs, then open the desired DBC.

The problem is, when I run the forms, I want to ensure that the forms use the currently opened DBC tables only.

The only way I seem to make this work is by going into the dataenvironment.opentables() method of each form and set the DBC location for each opened table like this;

THIS.CURSOR1.DATABASE = oapp.fullname_of_dbc
THIS.CURSOR2.DATABASE = oapp.fullname_of_dbc

Just wondering if there is a better way.

Thanks,
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform