Template Questions

  • Thread starter Thread starter OriginalStealth
  • Start date Start date
O

OriginalStealth

We have a .Net application that creates a report and the report has to be
exported to Excel. Once that happens I must do a lot of things to get the
report in presentation form. I am going to Save As the report under a
template name. Can I automate the following using VBA in the template? If
so, could someone paste code please. When template opens:

1. Switch to landscape
2. Set margins to fit on one page "width only"
3. Center Horizontally
4. Size row height to 12.75 (except first 10 rows)
5. Repeat Header on each page

Please help. Thanks in advance OS
 
OS,

One option is to set all those things in an Excel spreadsheet, then use .Net to open the spreadsheet
and write the data into it using Excel automation.

HTH,
Bernie
MS Excel MVP
 
That's a great suggestion Bernie but unfortunately I don't have access and we
are on the bottom of the todem pole for this change so I wanted to see if I
could get a template going for the group. That way they could export to the
template and when it opens they would be good.
 
Back
Top