Subject |
Re: User BDE Alias |
From |
Mervyn Bick <invalid@invalid.invalid> |
Date |
Sun, 6 Aug 2023 17:54:42 +0200 |
Newsgroups |
dbase.getting-started |
On 2023/08/06 16:06, Ketan G wrote:
> Yes, the code below is what I tried just a few minutes after my original post
> and this works fine, plus another advantage is that the table does not have to
> be prefixed with the database name in colons.
>
> Thanks all for the help and suggestions.
It works but bear in mind that if you run the command SET DATABASE TO
WHATEVER from the Control Panel, or in a program executed from the IDE,
the database displayed in the IDE Tables tab is changed to WHATEVER.
This will cause a problem for the next program you want to execute from
within the IDE if it expects its table to be in the same folder as the
program.
If a folder is selected in the combobox in the Tables tab the comboboxes
in the other tabs also change to that folder and selecting a different
folder in any of the tabs changes the display in the Tables tab.
If a database is selected in the combobox in the Table tab the other
comboboxes remain unchanged. Changing to a different folder in any of
the tabs does not change the setting in the Table tab.
In the long run you are likely to find that prefixing the table name
with the database name between colons gives less hassle than using SET
DATABASE TO WHATEVER.
If you use this approach in programs the OPEN DATABASE WHATEVER command
should be in a try...catch...endtry construct otherwise there will be an
error if you run the program a second time.
Mervyn.
|
|