Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 504
Default Window change event?

Is there such thing as a window change event?

I have code that resides in an add-in and I would like to have a macro in
there that would run whenever another open workbook is selected via windows
drop down or alt/tab??
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Window change event?

If you go into the VBE and click on the ThisWorkbook item in the project
explorer, you can use the dropdowns at the top of the righthand side window.

You can choose "Workbook" in the lefthand side dropdown and then choose either
Workbook_WindowActivate or Workbook_WindowDeactivate.


Kevin wrote:

Is there such thing as a window change event?

I have code that resides in an add-in and I would like to have a macro in
there that would run whenever another open workbook is selected via windows
drop down or alt/tab??


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 504
Default Window change event?

Thanks, I think I can make that work... I have an add in that all of my code
resides in and it opens different spreadsheets for each location. I wanted to
have something to keep people from selecting workbooks not having to do with
these particular spreadsheets while any of them are still open.

I'll have the windows_deactivate call a macro to check wether or not the
activeworkbook is part of the project or not...

Thanks again...

"Dave Peterson" wrote:

If you go into the VBE and click on the ThisWorkbook item in the project
explorer, you can use the dropdowns at the top of the righthand side window.

You can choose "Workbook" in the lefthand side dropdown and then choose either
Workbook_WindowActivate or Workbook_WindowDeactivate.


Kevin wrote:

Is there such thing as a window change event?

I have code that resides in an add-in and I would like to have a macro in
there that would run whenever another open workbook is selected via windows
drop down or alt/tab??


--

Dave Peterson

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Window Trigger Event. donwb Excel Programming 2 July 8th 08 08:04 AM
apply cell change event to single column - WorksheetChange Event [email protected] Excel Programming 6 May 4th 08 02:28 AM
new window event John[_113_] Excel Programming 2 July 8th 06 09:21 AM
MsgBox in Enter event causes combobox not to run Change event Richard Excel Programming 0 March 6th 06 02:52 PM
Window Event Nigel Excel Programming 2 April 29th 05 08:42 PM


All times are GMT +1. The time now is 04:52 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"