Saving Excel 2010 with out the file tab

pleased2help

New member
Joined
Jun 27, 2013
Messages
28
Reaction score
0
Points
0
Hi All, Can you help please, I have taken out all the headings, ribbons, scroll bars etc to leave just the spread sheet (Read only) I use:-

Sub hide()
Sheet2.Visible = xlSheetHidden
Sheet3.Visible = xlSheetHidden
Sheet4.Visible = xlSheetHidden
Application.DisplayFormulaBar = False
ActiveWindow.DisplayHeadings = False
ActiveWindow.DisplayWorkbookTabs = False
ActiveWindow.DisplayGridlines = False
ActiveWindow.DisplayOutline = False
ActiveWindow.DisplayHorizontalScrollBar = False
ActiveWindow.DisplayVerticalScrollBar = False
Application.ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",False)"
ThisWorkbook.Save
End Sub

when on the screen it clears down the sheet and saves ( with no file tab ), HOWEVER, when i reopen the saved sheet the file tab comes back !!! so frustrating Can any one help? as i dont want any one to resave the sheet.

Many thanks in Anticipation
 
Answer for Closing workbook with out saving and with out file tab VBA

Hi All, Can you help please, I have taken out all the headings, ribbons, scroll bars etc to leave just the spread sheet (Read only) I use:-

Sub hide()
Sheet2.Visible = xlSheetHidden
Sheet3.Visible = xlSheetHidden
Sheet4.Visible = xlSheetHidden
Application.DisplayFormulaBar = False
ActiveWindow.DisplayHeadings = False
ActiveWindow.DisplayWorkbookTabs = False
ActiveWindow.DisplayGridlines = False
ActiveWindow.DisplayOutline = False
ActiveWindow.DisplayHorizontalScrollBar = False
ActiveWindow.DisplayVerticalScrollBar = False
Application.ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",False)"
ThisWorkbook.Save
End Sub

when on the screen it clears down the sheet and saves ( with no file tab ), HOWEVER, when i reopen the saved sheet the file tab comes back !!! so frustrating Can any one help? as i dont want any one to resave the sheet.

Many thanks in Anticipation

After days searching around the internet managed to find a solution to closing a workbook without a save and also with no file tab on re opening Excel 2010....
The vba is not efficient as I am newby to this, so if it can be tidied up, any advice would be appreciated....

The following is saved in THISWORKBOOK

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ThisWorkbook.Saved = True
Application.Quit
End Sub
Private Sub Workbook_Open()
Sheet2.Visible = xlSheetHidden
Sheet3.Visible = xlSheetHidden
Sheet4.Visible = xlSheetHidden
Application.DisplayFormulaBar = False
ActiveWindow.DisplayHeadings = False
ActiveWindow.DisplayWorkbookTabs = False
ActiveWindow.DisplayGridlines = False
ActiveWindow.DisplayOutline = False
ActiveWindow.DisplayHorizontalScrollBar = False
ActiveWindow.DisplayVerticalScrollBar = False
Application.ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",False)"
ActiveWorkbook.Saved = True
End Sub

I hope it works for you
 
Last edited:
Back
Top