Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a 8 sheets with each 8 queries.
I use this macro to actualize all queries: Sub ActualizarConsultas() Dim QueryTables As QueryTables Dim query As QueryTable Dim ws As Worksheet Dim i As Integer Dim vArray As Variant Dim dteFecha As Date Dim j As Long With Application ' .ScreenUpdating = False .Calculation = xlCalculationManual End With 'Define names of sheets with queries to be updated vArray = Array("Brand1", "Brand2", "Brand3", "Brand4", "Brand5", "Brand6", "Brand7", "Brand8") 'Update queries For i = 0 To UBound(vArray) Set ws = Worksheets(vArray(i)) 'Select sheet For Each query In ws.QueryTables query.Refresh BackgroundQuery:=False 'Update query Next Next With Application ' .ScreenUpdating = True .Calculation = xlCalculationAutomatic End With 'MsgBox "Terminado", vbInformation, "END" End Sub I am afraid to use .ScreenUpdating = True. Could that not cause one query to overwrite rows of the query right below it because the screen does not update? TIA Martin |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Running speed of Micrsoft Query with Multiple parameters | Excel Discussion (Misc queries) | |||
VBA Apllication.run and macros when spreadsheet name changes | Excel Programming | |||
Code with query goes from greyhound to turtle speed | Excel Programming | |||
How can I Improve query speed? | Excel Programming | |||
Apllication.OnTime | Excel Programming |