Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I need to write a macro that will refresh or update about 10 queries that are
on another sheet. Automatically updating it when the file is opened is not what they want to have happen, can someone help me figure this out, I really am not too sure, thanks. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Josh,
As an example, the code below will refresh all queries in a sheet named "Sheet2". Sub Test Dim qry As QueryTable For Each qry In Sheets("Sheet2").QueryTables qry.Refresh BackgroundQuery:=True Next qry End Sub -- Hope that helps. Vergel Adriano "Josh Johansen" wrote: I need to write a macro that will refresh or update about 10 queries that are on another sheet. Automatically updating it when the file is opened is not what they want to have happen, can someone help me figure this out, I really am not too sure, thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel Macro to copy, paste and then update web queries | Excel Programming | |||
Running UPDATE and APPEND queries from Access in Excel | Excel Programming | |||
macro to delete specific row with queries embedded | Excel Programming | |||
Please Help...Multiple web queries and Macro help needed! | Excel Programming | |||
Executing multiple queries through a macro | Excel Discussion (Misc queries) |