Checking for existance of tables using VB in Access 2000

D

David Gartrell

Hi there,

I wonder if someone could help me please. I have an Access 2000 database
which needs to create a temporary table and then later delete it again (lets
call it 'tableA'). Is there a way (in VB) of checking whether the table
exists before executing subsequent code. 99% of the time it will exist, but
sometimes if there's a computer crash etc the table may be left behind when
it should be deleted.

Any help would be greatly appreciated.

many thanks

David.
 
J

jacksonmacd

If you *know* that it's not required, you can explicitly delete it
just before you create it. If you include an On Error Resume Next
statement before the delete command, then your program will proceed
correctly even if the table does not exist.


Hi there,

I wonder if someone could help me please. I have an Access 2000 database
which needs to create a temporary table and then later delete it again (lets
call it 'tableA'). Is there a way (in VB) of checking whether the table
exists before executing subsequent code. 99% of the time it will exist, but
sometimes if there's a computer crash etc the table may be left behind when
it should be deleted.

Any help would be greatly appreciated.

many thanks

David.
**********************[email protected]
remove uppercase letters for true email
http://www.geocities.com/jacksonmacd/ for info on MS Access security
 
Top