Using a submenu in a button

  • Thread starter Thread starter Joao
  • Start date Start date
J

Joao

I remember coding years ago in vb 6 something like this:

You press a commandbutton and a user-defined submenu appears to select
options...

Anyone knows an easy method to accomplish this in VBA?
 
Joao said:
I remember coding years ago in vb 6 something like this:

You press a commandbutton and a user-defined submenu appears to select
options...

Anyone knows an easy method to accomplish this in VBA?

Incredibly easy...

CommandBars![PopUpMenuName].ShowPopup

Of course, first you have to create you custom PopUp menu.
 
Thanks Brandt, but...
How do I create it??

Rick Brandt said:
Joao said:
I remember coding years ago in vb 6 something like this:

You press a commandbutton and a user-defined submenu appears to select
options...

Anyone knows an easy method to accomplish this in VBA?

Incredibly easy...

CommandBars![PopUpMenuName].ShowPopup

Of course, first you have to create you custom PopUp menu.
 
Joao said:
Thanks Brandt, but...
How do I create it??

Pre Access 2007...

Right-click any existing menu or toolbar and choose "Customize". In the
resulting dialog choose "New". Once you have defined a new command bar set
its Type to PopUp.
 
Thank you Rick! I missed the popup property.

Rick Brandt said:
Pre Access 2007...

Right-click any existing menu or toolbar and choose "Customize". In the
resulting dialog choose "New". Once you have defined a new command bar set
its Type to PopUp.
 
Back
Top