Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can you bypass MS generated message box 2

Status
Not open for further replies.

BH

Programmer
Oct 15, 2002
76
0
0
GB
Can anyone help?

I have set up a number of make table queries from one data source table.

From the new tables I then select the records and copy and paste these into other tables

This operation is all automated using a defined macro and works fine.

The problem I have is when the macro is running I have to keep answering messages i.e do you want to paste 10 new records etc. The answer is always yes so is there some way so these message boxes can be automatically defaulted to pressing the yes button or bypassed completely.

 
I'm not sure this is the right option, but I think it is.

In Access 97 (probably applies to 2000 as well) go to the Tools --> Options menu and choose the "Edit/Find" tab. There should be some check boxes for confirming record changes, action queries and Document deletes. If you uncheck "record changes" I think that will stop your prompts.

Warning! This is an application setting for your computer for all Access databases. It doesn't just apply to this one database. Maq [americanflag]
<insert witty signature here>
 
Thanks Maquis

Nearly worked

Unchecked as you suggested, some of the validation message boxes do not appear now but some still do. The ones that are still appearing are 'you are about to delete....' and 'large amount of data onto clipboard.....'

Any more suggestions?
 
I would suggest using queries to delete and move the records rather than straight cut and pasting. Those messages won't appear if you use queries. (Assuming you uncheck the confirm action queries box). Maq [americanflag]
<insert witty signature here>
 
Thanks again

I will rework it and give it a go.
 
How's about adding in your code

DoCmd.SetWarnings False

and at the end

DoCmd.SetWarnings True

this turns off *all* messages in Access 97
 
I think Prof63 missed that you're using a macro. The macro equivalent is the SetWarnings action. You turn it Off at the start of your macro, and be sure to turn it On again when you're done.

SetWarnings turns off all warning messages for this execution of Access. You might want to create a separate macro with just SetWarnings On in it. Then if something happens to interrupt your first macro, preventing it from finishing, you can run the second macro to turn the warning messages back on. If you don't, you may miss important messages in other things you do. Rick Sprague
 
Thankyou everyone for your help

For my application RickSpr suggestion has worked spot on.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top