Adding two actions with Comand Button Wizard

  • Thread starter Tom via AccessMonster.com
  • Start date
T

Tom via AccessMonster.com

Can I use the Comand Button Wizard to add more than one action to a comand
button? I would like to open one form and close the current form with a
command button. Do I need to use a macro?

Tom
 
F

fredg

Can I use the Comand Button Wizard to add more than one action to a comand
button? I would like to open one form and close the current form with a
command button. Do I need to use a macro?

Tom

Just add the second action to the first action in the order you wish
them to occur:

DoCmd.OpenForm "FormName"
DoCmd.Close acForm, Me.Name
 
J

John Vinson

Can I use the Comand Button Wizard to add more than one action to a comand
button? I would like to open one form and close the current form with a
command button. Do I need to use a macro?

Tom

The Wizards aren't that clever; but you can use the wizard to do one
of these actions, and then edit the VBA code which the wizard created
to add the other action. See Fred's suggestion for just how to do so.

John W. Vinson[MVP]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top