how to create button commande to refresh data in query in excel 2.
I have a excel spreedsheet that contain external data. I would like to put a
button in the excel sheet to update the sheet without doing right click and refresh. My user here are very dummies. |
Jean Francois
If this is external data then bringing it in should launch the external data toolbar. They will only need to click the exclamation (!) mark. Seems like re-inventing the wheel. If you must then put a button on the worksheet and assign it to this macro Sub refreshdata() Dim wks As Worksheet Dim qryTab As QueryTable Set wks = ActiveSheet For Each qryTab In wks.QueryTables qryTab.Refresh Next qryTab End Sub -- HTH Nick Hodge Microsoft MVP - Excel Southampton, England HIS "Jean-Francois" wrote in message ... I have a excel spreedsheet that contain external data. I would like to put a button in the excel sheet to update the sheet without doing right click and refresh. My user here are very dummies. |
All times are GMT +1. The time now is 02:02 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com