Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Jean-Francois
 
Posts: n/a
Default 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.
  #2   Report Post  
Nick Hodge
 
Posts: n/a
Default

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.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2003 FAILS, but Excel 2000 SUCCEEDS ??? Richard Excel Discussion (Misc queries) 2 May 13th 23 11:46 AM
Disable Query Refresh warning dialog box in Excel 2003 Jeff Koons Excel Discussion (Misc queries) 2 December 1st 05 04:08 PM
Fetching External Data from Excel Sri Excel Discussion (Misc queries) 2 January 3rd 05 11:46 AM
Refreshing Access data in Excel Jimmy G Excel Discussion (Misc queries) 0 December 21st 04 03:53 PM
How to use a Access Query that as a parameter into Excel database query Karen Middleton Excel Discussion (Misc queries) 1 December 13th 04 07:54 PM


All times are GMT +1. The time now is 03:05 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"