Tuesday, July 20, 2010

How attached macro into button?

Sometime you feel very difficult to run macro from toolbars because too many step and macro inside. Therefore what you can do is to create button and attached macro to it. There are a few methods you can do:
  • Standard Text Box
  • Custom button
For no 1) Standard Text Box the step you follow as below:
  1. Use your creativity to edit this text box look like actual button.
  2. Move your cursor at the edge of text box and right click.

  3. Assign macro dialog box will open then choose macro and click OK.

You’re done for no 1), every time you click this fake button your macro will start working.

For no 2) Custom buttons the step is more complicated:
  1. Point to Customize on the Tools menu.



  2. Inside Customize dialog box choose Commands tab and select macro.



  3. Click and drag smiley button anywhere in between any button you like (as below) – No limit to visual basic toolbar only



  4. Close customize dialog box and click button after drag(smiley face) then assign macro dialog box will open then choose macro and click OK.(Same as text box item 31c)
You’re done.
Note:
  • For this type of button it will permanently attach to any excel file as long the original file still inside your computer.
  • The outlook for this button also can be change or customize. (May next tutorial… he he :)

No comments:

Post a Comment