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!

New user : Don't know how to bypass the "You are about to update"

Status
Not open for further replies.

ashishh

Programmer
Jul 19, 2002
43
0
0
US
Hi all,

Thanks for your patience. This might be a trivial question but I seem to be stuck on it, partly because I'm new to Access.

I have this form in which I have a macro which updates another table based on some selection on this form. This macro is triggered on after update event.

I get this pop-up window confirming the number of records being updated. example "you are about to update 1 row(s)" I would like to avoid getting this window and directly update the rows without the hassle of confirming every time.

Is there anything I can do to achieve this.

Thanks,
Ashish
 
Look under Tools|Options|Edit/Find|Confirm and uncheck the three boxes there.
 
[tt]
Hi Ashish:

Not a trivial question at all.

You can turn such 'warnings' on and off, either in a macro or in the code behind the form.

In the macro, select setwarnings and in the property box at the bottom of the form you can select "on" or "off" (it might be "yes" or "no", I don't remember.)

In the code behind the form I think it's

SetWarnings On or SetWarnings Off

I learned to be certain to turn the warnings back on after the procedure was finished, for error messages, etc.

Hope this helps.

Cheers,

[glasses][tt]Gus Brunston - Access2000(DAO)
Skill level based on 1-10: 7, on the way to 6, and beyond!
Webmaster: www.rentdex.com[/tt]
 
In a macro:
Action = SetWarnings Argument = No
insert queries, etc as necessary
Action = SetWarnings Argument = Yes

In code:
DoCmd.SetWarnings False
queries, etc
DoCmd.SetWarnings True

 
Thanks guys. It was very helpful. Appreciate all the help.

Keep up the good work. Sorry about the delayed response from me.

Ashish
 
You may not know that the standard way to award thanks is to give stars, that is, to click on the link "Thank X for this valuable post!" :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top