View Full Version : Name a Excel Spreadsheet
08-17-2005, 10:04 AM
Is there a way i can add a name to an excel spreadsheet. I know I can send data to excel usuing this
Response.ContentType = "application/vnd.ms-excel"
08-17-2005, 08:18 PM
Do you mean name the sheet or the file or something else?
08-18-2005, 09:08 AM
yes, I mean the sheet.
08-18-2005, 03:16 PM
Here is your answer:
This is important for you:
'Rename Sheet1 to "Orders", rename Sheet2 to "Totals" and remove Sheet3
Set oOrdersSheet = oSS.Worksheets(1)
oOrdersSheet.Name = "Orders"
Set oTotalsSheet = oSS.Worksheets(2)
oTotalsSheet.Name = "Totals"
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.