Solved

overwrite a table without confirm to an external MDB

Posted on 2004-08-05
4
620 Views
Last Modified: 2010-07-27
I want to export, with a macro or code, a few tables or make table queries to an external MDB.

If I do a make table query or macro CopyObject or code DoCmd.CopyObject to make or copy a table to external mdb and the table exists in the external mdb I get a 'already exists, overwrite?' confirmation.  I don't want to see these confirmation.
 
Is there a way to override this? I can delete a table using code within the current db without confirmation, in order to then recreate it in current db so don't get this message. But can't seem to do same in an external db.

tx,

Luke
0
Comment
Question by:LukeB
  • 2
  • 2
4 Comments
 
LVL 26

Expert Comment

by:dannywareham
ID: 11724925
I think you can setwarnings to false for this...
0
 
LVL 1

Author Comment

by:LukeB
ID: 11725885
ok, in the macro (and how) or in code (and how) ?
0
 
LVL 26

Accepted Solution

by:
dannywareham earned 175 total points
ID: 11726082
Either
In marco (setwarnings then in bottom window put No) - it's in the dropdown list

In code
DoCmd.SetWarnings (False)

Using a macro is probably easier if you're unsure of coding. (and its dead simple)
At the end of the macro, put setwarnings to yes though
0
 
LVL 1

Author Comment

by:LukeB
ID: 11733083
Hi Danny,

perfect, thanks
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction When developing Access applications, often we need to know whether an object exists.  This article presents a quick and reliable routine to determine if an object exists without that object being opened. If you wanted to inspect/ite…
Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question