Share workbook affects my "options menu" configuration

G

Guest

A share workbook affects my "options/ view/ windows in task bar"
configuration each time I open it. How can I avoid it? I have modified and
saved this option in the share workbook but it hasn't solved the problem.
 
D

Dave Peterson

From a previous post:

Do you use Shared workbooks. If yes, there's a problem with that setting and
shared workbooks (but it's been fixed in xl2002--so that should help <bg>).

You could use an application event that resets that option each time a workbook
opens--until you upgrade:

If you like this idea:

Start a new workbook
Alt-F11 to get the VBE (where macros live)
hit ctrl-R to see the project explorer (a lot like windows explorer)
select your project (book1) VBAProject
right click and select Insert|Class Module
Then hit F4 (to see its properties)
Change the (name) property from Class1 to WinInTaskBar

Then paste this in that code window to the right:

Option Explicit
Public WithEvents xlApp As Excel.Application
Private Sub xlApp_NewWorkbook(ByVal Wb As Workbook)
Application.ShowWindowsInTaskbar = True
End Sub
Private Sub xlApp_WorkbookOpen(ByVal Wb As Workbook)
Application.ShowWindowsInTaskbar = True
End Sub


Now doubleclick on the ThisWorkbook object of this same project.
(you might have to expand all the levels to see it)

Paste this in the code window to the right.

Dim myWinInTaskBar As WinInTaskBar
Private Sub Workbook_Open()
Set myWinInTaskBar = New WinInTaskBar
Set myWinInTaskBar.xlApp = Application
End Sub
Private Sub Workbook_Close()
Set myWinInTaskBar.xlApp = Nothing
End Sub

Now back to excel and save your workbook--but save it as an addin and store it
in your XLStart folder.

By saving it as an addin, it'll be invisible to you when you're in excel. By
storing it in XLStart, your addin will load whenever you start excel.

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top