sql - Export excel file with macro saved in it -


i have vba function in access runs sql commands , @ end exports 1 of tables excel. wondering if there way save macro in excel spreadsheet when exports it? posted line of code below exports table:

docmd.transferspreadsheet acexport, acspreadsheettypeexcel12, "pdfverified", "rev-h" 

as retailcoder stated first enable programmatic access project checking box @ options->trustcenter->trustcentersettings->macrosettings->trustaccesstothevbaprojectobjectmodel. import module with

excelworkbookobject.vbproject.vbcomponents.import "moduleaddressandname" 

Comments

Popular posts from this blog

javascript - How to synchronize the Three.js and HTML/SVG coordinate systems (especially w.r.t. the y-axis)? -

javascript - How do I find how many occurences are there of a highlighted string, and which occurence is it? -

java - Reading data from multiple zip files and combining them to one -