So I've been trying to add a right-click menu item to my workbook. i.e. When you right-click on a cell, in addition to all the normal right-click-cell commands (copy, cut, paste, etc) there would be an additional command called "Draft Player" at the bottom of he list. It would run a macro I've defined in object Sheet1.
I had it set up as follows:
In object Sheet1 I had
In object "This Workbook" I had
The problem was that it didn't work. If I opened the workbook I received a "Compile Error: Sub or function not defined". This error pointed to the Private Sub Workbook_Open().
Similarly, when I closed the workbook I received a "Compile Error: Sub or function not defined". This error pointed to the Private Sub Workbook_BeforeClose(Cancel As Boolean).
So I thought maybe I had to move the two subs
Sub AddToShortcut
Sub DeleteFromShortcut
from object: Sheet1 to object: This Workbook. Which I did. I saved and closed the workbook. Now the workbook does not open! When I double click the file name to open it, just the PERSONAL.XLSB file opens! How do I get my workbook back?!?
I tried disabling macros to see if it would open that way, but no luck.
Ack! Help me Obi Wan. You're my only hope!!
Bookmarks