call code from toolbar menu item

  • Thread starter Thread starter Bill D
  • Start date Start date
B

Bill D

What is best way to call code (say a proc in a form) from the menu item
created in a custom toolbar. There is an OnAction property that says it will
take a macro or a function but not having luck with that.
 
You can make the proc public inside the form, but it's often wiser to move
it to a standard module.
(Make sure you resolve any references to other form-specific values.)
Declare the proc as a Function - any return value will be ignored.
Call it from the OnAction property by using
=MyProc()

HTH
- Turtle
 
Back
Top