Forum Discussion
How to automatically update data when opening the Excel file?
- 6 years ago
You can write a macro with VBA that triggers on open with the command Refresh.All
That will refresh all queries in the workbook.
If this works for you, please mark it as the solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
- 6 years ago
I am not aware of that, and would probably advise against it. If you had a shared read only account to your database that anyone that would open your file had access to, that should work.
Regards,
Pat
You can write a macro with VBA that triggers on open with the command Refresh.All
That will refresh all queries in the workbook.
If this works for you, please mark it as the solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
- Anonymous6 years agoNot applicable
mahoneypat Is there a way to do impersonation in excel macro? Thanks!
- mahoneypat6 years agoMicrosoft Employee
I am not aware of that, and would probably advise against it. If you had a shared read only account to your database that anyone that would open your file had access to, that should work.
Regards,
Pat