Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 265
Default 2 excel windows

Hi, I'm tryng to accomplish something difficult to explain:
If you open a workbook (ex. hello.xls) and the you go to file--open another
file (ex. hello2.xls) then you have hello.xls and hello2.xls in the same
excel window, but if you open hello.xls ant then you go to the excels general
icon (the one that opens an excel window with a new woorkbook on it) ant
then you choose file--open hello2.xls then you have 2 excel windows, now my
problem: I have my firs book hello.xls with all the menu bars disabled but
the woorkbook hello2.xls needs all the menu bars enabled so if I open my
workbook as explained on the second way to open the file I can have my file
hello.xls without the menu bars and hello2.xls with all the menu bars
enabled; BUT I NEED TO OPEN EXCELS GENERAL ICON TO ACHIVE THIS, I mean, I
cant paste a shortcut in the desktop because when I open the second file, it
opens in the excels window of my first file.
It's very important that the user of my program could open the file from the
desktop, so there is a way to do what I want?????
Hope this have sence, TIA

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 17
Default 2 excel windows

Hi Filo666,

See if this code below works for you.

Sub Auto_Open()
On Error Resume Next
SetCurrentDirectory ThisWorkbook.Path
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Application.DisplayFullScreen = True
ActiveWindow.DisplayGridlines = False
ActiveWindow.DisplayHeadings = False
With ActiveWindow
.DisplayHorizontalScrollBar = False
.DisplayVerticalScrollBar = False
.DisplayWorkbookTabs = False
End With
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub

Sub Auto_Close()
On Error Resume Next
Application.ScreenUpdating = False
Application.DisplayAlerts = False
With ActiveWindow
.DisplayHorizontalScrollBar = True
.DisplayVerticalScrollBar = True
.DisplayWorkbookTabs = True
End With
Application.DisplayFullScreen = False
ActiveWindow.DisplayHeadings = True
Application.DisplayAlerts = True
Application.ScreenUpdating = True
Set objExcel = GetObject(, "Excel.Application")
objExcel.Quit
Application.WindowState = xlMinimized
ThisWorkbook.Close SAVECHANGES:=False
End Sub

"filo666" wrote:

Hi, I'm tryng to accomplish something difficult to explain:
If you open a workbook (ex. hello.xls) and the you go to file--open another
file (ex. hello2.xls) then you have hello.xls and hello2.xls in the same
excel window, but if you open hello.xls ant then you go to the excels general
icon (the one that opens an excel window with a new woorkbook on it) ant
then you choose file--open hello2.xls then you have 2 excel windows, now my
problem: I have my firs book hello.xls with all the menu bars disabled but
the woorkbook hello2.xls needs all the menu bars enabled so if I open my
workbook as explained on the second way to open the file I can have my file
hello.xls without the menu bars and hello2.xls with all the menu bars
enabled; BUT I NEED TO OPEN EXCELS GENERAL ICON TO ACHIVE THIS, I mean, I
cant paste a shortcut in the desktop because when I open the second file, it
opens in the excels window of my first file.
It's very important that the user of my program could open the file from the
desktop, so there is a way to do what I want?????
Hope this have sence, TIA

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
Excel 2007 with two windows in Windows 7 Bob Excel Discussion (Misc queries) 0 January 15th 10 02:20 PM
i want all windows in one excel frame (windows in taskbar) Subramanya Excel Discussion (Misc queries) 1 December 18th 09 03:14 PM
cannot open exel from windows xp in windows vista and visa versa lildiana New Users to Excel 4 February 25th 09 07:26 PM
can windows vista edit shared document from windows xp sasa Excel Worksheet Functions 1 January 9th 08 06:44 PM
Use Windows Script to run Windows Explorer Search? Ian Elliott[_3_] Excel Programming 0 January 12th 04 05:03 PM


All times are GMT +1. The time now is 12:02 PM.

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

About Us

"It's about Microsoft Excel"