Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
The code in ThisWorkbook.Workbook_Open is not getting executed when the
workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
Hi
you have to put this code in your workbook module ('ThisWorkbook') -- Regards Frank Kabel Frankfurt, Germany "Jim Zeeb" schrieb im Newsbeitrag ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
Hi Jim,
One possibility is that EnableEvents has been set to false, perhaps by interrrupted code operation. In case this is the reason, run: Sub Test() Application.EnableEvents = True End Sub --- Regards, Norman "Jim Zeeb" wrote in message ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
It is in ThisWorkbook
"Frank Kabel" wrote: Hi you have to put this code in your workbook module ('ThisWorkbook') -- Regards Frank Kabel Frankfurt, Germany "Jim Zeeb" schrieb im Newsbeitrag ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
Hiu
then post your complete code -- Regards Frank Kabel Frankfurt, Germany "Jim Zeeb" schrieb im Newsbeitrag ... It is in ThisWorkbook "Frank Kabel" wrote: Hi you have to put this code in your workbook module ('ThisWorkbook') -- Regards Frank Kabel Frankfurt, Germany "Jim Zeeb" schrieb im Newsbeitrag ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
I do manipulate EnableEvents.
Does this persist between invocations of Excel? "Norman Jones" wrote: Hi Jim, One possibility is that EnableEvents has been set to false, perhaps by interrrupted code operation. In case this is the reason, run: Sub Test() Application.EnableEvents = True End Sub --- Regards, Norman "Jim Zeeb" wrote in message ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
Hi Jim,
Does this persist between invocations of Excel? No, Events are enabled by default each time Excel is opened. So if your Workbook_Open code is not firing after closing and re-opening Excel, my guess was wrong. If, howver, Events are set to false and the workbook is re-opened, the event code would not fire. As Frank suggested, post your code. If the code is in the correct module (ThisWorkbook) and events are set to true, the only remaining factor that I can think of is the code itself. --- Regards, Norman "Jim Zeeb" wrote in message ... I do manipulate EnableEvents. Does this persist between invocations of Excel? "Norman Jones" wrote: Hi Jim, One possibility is that EnableEvents has been set to false, perhaps by interrrupted code operation. In case this is the reason, run: Sub Test() Application.EnableEvents = True End Sub --- Regards, Norman "Jim Zeeb" wrote in message ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
Hi Jim,
One other thought, how are you opening the workbook? --- Regards, Norman "Jim Zeeb" wrote in message ... I do manipulate EnableEvents. Does this persist between invocations of Excel? "Norman Jones" wrote: Hi Jim, One possibility is that EnableEvents has been set to false, perhaps by interrrupted code operation. In case this is the reason, run: Sub Test() Application.EnableEvents = True End Sub --- Regards, Norman "Jim Zeeb" wrote in message ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance |
#9
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook_Open
And to piggyback on Norman's leading question...
If you're opening the workbook via a macro and use a shortcut key that includes the Shift key, remove the shiftkey from the shortcut key combo. Holding the Shiftkey down when you're opening a workbook stops the auto_open and workbook_open code from running. And excel gets confused about your shiftkey in the shortcut key combination. Norman Jones wrote: Hi Jim, One other thought, how are you opening the workbook? --- Regards, Norman "Jim Zeeb" wrote in message ... I do manipulate EnableEvents. Does this persist between invocations of Excel? "Norman Jones" wrote: Hi Jim, One possibility is that EnableEvents has been set to false, perhaps by interrrupted code operation. In case this is the reason, run: Sub Test() Application.EnableEvents = True End Sub --- Regards, Norman "Jim Zeeb" wrote in message ... The code in ThisWorkbook.Workbook_Open is not getting executed when the workbook is opened. I put a Msgbox right at the top of the code and I never see it. InTHANKSAdvance -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Workbook_Open () | Excel Discussion (Misc queries) | |||
workbook_open | Excel Programming | |||
Trouble with Workbook_Open() | Excel Programming | |||
Workbook_Open | Excel Programming | |||
Help with Workbook_Open | Excel Programming |