Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

OutputTo Excel Doesn't use Book.xlt like normal

Status
Not open for further replies.

Dirtbike

IS-IT--Management
Dec 9, 2002
81
US
When I:

DoCmd.OutputTo acQuery, "Loc003WOcouldbuild", "MicrosoftExcelBiff8(*.xls)", "", True, "D:\Program Files\Microsoft Office\OFFICE11\XLSTART\Book.xlt", 0

it doesn't follow the rules I set up in Book.xlt like custom headers, repeat rows. etc. Even when I explicitly call out the location of templates in TOOLS -> OPTIONS -> GENERAL. What gives? How can I apply settings to the sheet after it is spawned from Access? Please don't say to load up personal.xls with macros.....unless of course that is the only solution... :)

Scott
 
Output the query to the template, the user will have to do "SaveA As" to save it, leaving the template intact.
Code:
DoCmd.OutputTo acQuery, "Loc003WOcouldbuild", "Microsoft Excel(*.xls)", "D:\Program Files\Microsoft Office\OFFICE11\XLSTART\Book.xlt", True

VBSlammer
redinvader3walking.gif

"You just have to know which screws to turn." - Professor Bob
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top