Link to home
Create AccountLog in
Avatar of route217
route217Flag for United Kingdom of Great Britain and Northern Ireland

asked on

Personal xlsb Macro

Hi Experts (cannot see the error of my ways)

i have followed the instruction on the previous question....see link below..
https://www.experts-exchange.com/questions/28170750/how-to-run-a-specific-macro-when-excel-is-open.html


The problem i have is when i open up excel 2007.....and press ALT + F8 i am getting an error on the macro stored in ThisWorkbook

on link frmMacroSelector.Show (Compile Error, Varible not defined)

Option Explicit

Private Sub Workbook_Open()
Application.OnKey "%{F8}", "ThisWorkbook.MacroList"
End Sub

Private Sub MacroList()

frmMacroSelector.Show

End Sub

Open in new window

Avatar of Joe Howard
Joe Howard
Flag of United States of America image

It seems like you don't have a Userform named frmMacroSelector.

And that would make sense if you just put your macros in Personal.xlsb instead of creating the macro selector form.
Avatar of route217

ASKER

Hi Macroshadow....

How would i create the userform named frmMacroSelector......new to vba.......stuff

and many thanks for the feedback....
hi macrodhadow...

can we not just lunch the standard form when hitting Alt +F8....and then selecting...macro in and then the Personal. xlsb....?
ASKER CERTIFIED SOLUTION
Avatar of Joe Howard
Joe Howard
Flag of United States of America image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Hi macroshadow...

Excellent feedback...

one silly question point 1. as above...

When you say open Personal.xlsb....i do not have a file just the Personal.xlsb in (Open the VBE (Alt+F11)
Well, download it from the link.
Thanks. ...

solved. ...excellent feedback. ..