Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 5 of 5

Thread: Activating macro with a Toolbar

  1. #1
    New Member
    Join Date
    Apr 2002
    Posts
    7
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I have two XLA containing macro (setup.xla and main.xla).

    I have a toolbar with button that should start macro.

    I want to set the button with a macro from SETUP.XLA to start macro from MAIN.XLA.

    My line in SETUP.XLA, to set the button, is :
    Toolbars(sTBName).ToolbarButtons(TB_POSOPENTOOL).OnAction = StartProgram

    --> [StartProgram] is a macro in the MAIN.XLA file

    The problem i get is when i clic on the button Excel is looking for the macro [StartProgram] in SETUP.XLA and can't find it (because it's in MAIN.XLA).

    Is there any way to specify that the macro to start onAction is located in the MAIN.XLA and not in SETUP.XLA ?

    Thanks !


  2. #2
    New Member
    Join Date
    Apr 2002
    Posts
    7
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I really need help with this one. I can't find anything in books...

  3. #3
    Board Regular
    Join Date
    Apr 2002
    Location
    Minnesota
    Posts
    821
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Why can't you just assign the macro from main.xla to the button without referencing setup.xla?

  4. #4
    New Member
    Join Date
    Apr 2002
    Posts
    7
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-04-22 07:26, klb wrote:
    Why can't you just assign the macro from main.xla to the button without referencing setup.xla?
    It would long to explain, but i cannot...

    I try to figure if there is a way to do it like that because i need it to work like that. I hope there is a solution !

  5. #5
    New Member
    Join Date
    Apr 2002
    Posts
    7
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    No one has another idea ?

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •