MrExcel Publishing
Your One Stop for Excel Tips & Solutions

Open with 2 windows visible


Posted by Jim on November 26, 2001 9:54 AM

I have 2 unrelated tasks I'd like to accomplish. I'll post these as two separate items.
First, the file is saved with 2 windows (different views of the same file) open and tiled vertically. Every time I open the file, I want it to open with both windows open and tiled vertically even if the last file opened in Excel was maximized.


Posted by Mark O'Brien on November 26, 2001 2:08 PM

Again, very doable.

Assuming that the user (or you) have only maximised one of the windows and that both of the windows are still there, you simply need to follow these instructions:

1. Open the worksheet
2. Right Click on a Sheet Tab and select "View Code"
3. On the project Navigator double click on "ThisWorkbook"
3. Insert this code:

Private Sub Workbook_Open()
ActiveWindow.WindowState = xlNormal
End Sub


Any problems, just repost

Mark