I am currenly exporting data from my .asp page to Excel. In my code, I dynamically create html tables based on selection a user made on the previous page. For each of these tables, I am creating a separate worksheet in Excel.
How do I:
1. Add only the worksheets that I generate to the Excel workbook (Excel defaults to already having 3 worksheets in the workbook then when I add mine, I have 3 blank worksheets plus the ones I add).
2. How do I arrange the worksheets in the order. Currently, if there are 3 html tables, I generate 3 worksheets. The tabs in my excel workbook look like this: sheet6, sheet5, sheet4, sheet1, sheet2, sheet3.)
3. How do I change the name of the tab using code, from something like: sheet1 to "1999 Activity Report".
4. How can I make the columns autofit using code? And can I bold line 1 and 2 which is the report title and field heading respectively?
5. How can I prompt the user to save the worksheet to there hard drive? Currently, I am using:
xlWorksheet.SaveAs Server.MapPath(".") & "\" & strFile