PDA

View Full Version : [SOLVED:] How to enable macro



Mister_joe
07-08-2014, 04:11 AM
Hi All,
I am looking to export data from an Access file to a macro-enabled Excel file. For now, I have no idea how to use codes in Access to open the Excel file and enable the Macro on the Excel file before populating it with the data imported from the Access database. Please, suggest possible options that can lead me to the end goal. This is very important for me.

In case I haven't made it clear enough, please, see the attached image file. Rather than do this manually, I need to use codes to do it.

Thanks.

westconn1
07-08-2014, 04:43 AM
if you are trying to do this by code, you may as well reduce your excel default macro security settings

Mister_joe
07-08-2014, 04:07 PM
Thanks you Sir. Eh ... I cannot say that I know how to do this - reduce the excel default macro security settings.

Jan Karel Pieterse
07-09-2014, 03:04 AM
If you open the file from Access by automating Excel, macros should be enabled automatically, regardless of your macro security settings.

Mister_joe
07-09-2014, 08:32 AM
A very big thank you, Mr. Jan. The macro was enabled automatically. This is a significant step forward for me, although I reckon that I may run into other issues when I actually start to populate the Excel worksheets. I am counting on good people like you and every contributor to this forum to help me out. Much respect!

Jan Karel Pieterse
07-09-2014, 08:38 AM
You are welcome!