View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Zack Barresse Zack Barresse is offline
external usenet poster
 
Posts: 124
Default Edit VBA Code without opening the workbook

Hi there,

Try taking a look at the EnableEvents property. I use something like this
to call before/after running code to optimize it slightly...

Public Sub ToggleEvents(ByVal blnState As Boolean)
'Originally written by firefytr
With Application
.DisplayAlerts = blnState
.EnableEvents = blnState
.ScreenUpdating = blnState
If blnState Then .CutCopyMode = False
If blnState Then .StatusBar = False
End With
End Sub

HTH

--
Zack Barresse



"pwrichcreek" wrote in message
...
I have VBA event code in an EXCEL workbook that goes into a never-ending
loop. I know what the problem is -- it triggers its own event! -- but I
don't
know how to edit the errant code without opening the workbook. Is there a
way
to edit the code without opening the workbook?

TIA,

Phil