Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
SaveAs and Hidden Workbooks
When I use the save as command to create a new file,
How do I set the attributes to hidden? So the Workbook does not show up in the explorer window. Workbooks.Open Filename:= _ "C:\Documents and Settings\All Users\Documents\" & _ "OFFICE SKILLS\Invoice_AND_Total_Sheet.xls " Workbooks("Invoice_AND_Total_Sheet.xls").SaveAs _ FolderNme & _ "\" & "Invoice_AND_Total_Sheet.xls" Workbooks("Invoice_AND_Total_Sheet.xls").Close |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
SaveAs and Hidden Workbooks
Take a look at the SetAttr command in VBA's help:
dim myfilename as string myfilename = FolderNme & "\" & "Invoice_AND_Total_Sheet.xls" 'open, save, close SetAttr myfilename, vbHidden But if you're only opening it to save it to a different location, take a look at FileCopy in VBA's help. You could just copy it to the new location. === Just an aside: I show all files in windows explorer--including hidden. So this technique may not be 100% effective. wtpcomplab wrote: When I use the save as command to create a new file, How do I set the attributes to hidden? So the Workbook does not show up in the explorer window. Workbooks.Open Filename:= _ "C:\Documents and Settings\All Users\Documents\" & _ "OFFICE SKILLS\Invoice_AND_Total_Sheet.xls " Workbooks("Invoice_AND_Total_Sheet.xls").SaveAs _ FolderNme & _ "\" & "Invoice_AND_Total_Sheet.xls" Workbooks("Invoice_AND_Total_Sheet.xls").Close -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
2007 Worksheet, Hidden Columns, .CSV Format Saves Hidden Column Da | Excel Discussion (Misc queries) | |||
Hidden Columns in Shared Workbooks | Excel Discussion (Misc queries) | |||
Hidden Columns in Shared Workbooks | Setting up and Configuration of Excel | |||
References to open/hidden workbooks become hard-coded in formulas - 2003 | Excel Discussion (Misc queries) | |||
References to open/hidden workbooks become hard-coded in formulas- 2003 | Excel Programming |