View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_3_] Bob Phillips[_3_] is offline
external usenet poster
 
Posts: 2,420
Default Before Worksheet Close

I can't see it because that sheet is not deactivated until something else is
activated.

--
__________________________________
HTH

Bob

"jswalsh33" wrote in message
...
Bob,

That works good, but it allows the newly selected worksheet to be
activated
before the the Deactivate code operates. I tried putting in
"Application.ScreenUpdating = False" as the first line of code but that
did
not prevent it. Is there a way to keep the screen from switching to the
newly
selected worksheets?

Thanks Again,

Jim Walsh

"Bob Phillips" wrote:

Private Sub Worksheet_Deactivate()
....your code
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--
__________________________________
HTH

Bob

"jswalsh33" wrote in message
...
Is there a way to run a particular macro when focus is change from a
particular worksheet to any other worksheet by selecting another
worksheet?

Thanks for your help.

Jim Walsh