Add tables to DataEnvironments at run-time

Add tables to DataEnvironments at run-time

Post by Wong Tang-Fung, Wyat » Thu, 12 Oct 1995 04:00:00


   How do I add tables to the DataEnvironment at run-time ? What I mean=20
is I had no idea on which tables needed to be open, so once the form is=20
started, I then add the appropriate tables to the DataEnvironment, and=20
the tables name _may_ change !

   There is an OpenTable method but I had no idea on how to use it, I=20
guess it is where I should put my code.

   Pls give examples...

Best Regards,
\/\/y=E0tt \/\/ong

| Internet e-mail:                                                    |



1. Adding Physical Field to a Table at Run-Time

I need to add a field to a DBase and Paradox table (a physical field, that
should be saved
in the DBF/DB file). Is there a way to do this in Delphi code, without
calling a BDE function?
I tried adding a FieldDef and then calling the CreateField method, but it
didn't add the field in
the table. Do I need to delete the table and create it with the added field

I know the DbiDoRestructure BDE function can do the job, but it seems quite
heavy to code. I would prefer a Delphi function that encapsulates this
instead... If it
doesn't exist, an example of the BDE function would be great, since my
on this is very basic!

Any help would be greatly appreciated.
Please send me a e-mail, since I'm afraid I could miss the reply!

Martin Angers
Let's keep knowledge sharing
one of the few remainings of the
human generosity.

2. oracle installation

3. Help: Adding DataEnvironment Child Command Screws Up DataEnvironment

4. Passing objects to VB created ole servers

5. Add a field to a table in run time

6. WANTED: FAQ on free databases

7. Adding a Password to a table at run-time

8. help: how do you find oracle home on windows

9. Changing Active database in DataEnvironment at run time?

10. Modify DataEnvironment Connection Strings at Run-Time

11. DataEnvironment SQL change at run time