Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / New Users / April 2006

Tip: Looking for answers? Try searching our database.

Macros and Conditionals

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Dj - 20 Apr 2006 14:14 GMT
I have a macro that does the following... msg box, import table (enter date),
append imported table to existing table, delete the imported table, msg box.  
In the event someone starts the macro but didn't mean to, at the point where
they enter the date for the append query, they can click cancel which will
halt the macro.  Problem is, that leave the imported table.  I tried deleting
the table first, but if the table doesn't exist because the last macro run
was complete and successful, I get a error and the macro halts.
I'm sure a condional in the macro is the answer for me, but I can't find any
real help in my books.  Ideally, my conditional would say "if temporary
imported table exists, then action delete it".  Can anyone tell me how to
write a conditional in a macro that says "If table exists".  Thx, Dj
NetworkTrade - 20 Apr 2006 20:01 GMT
you can create a new macro that deletes a table

your only question is when/what should trigger that macro.... you might be
able to use that same cancel button...or maybe create a second "Are you
sure?" button as an excuse to have a second clickable event to use...

you could use the exit event....

you have several options to play with....
Signature

NTC

> I have a macro that does the following... msg box, import table (enter date),
> append imported table to existing table, delete the imported table, msg box.  
[quoted text clipped - 7 lines]
> imported table exists, then action delete it".  Can anyone tell me how to
> write a conditional in a macro that says "If table exists".  Thx, Dj
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.