View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default waiting for data refresh before continuing VBA sub

Set the backgroundQuery property to false

This should make your macro wait.

--
Regards,
Tom Ogilvy



David Macqueen wrote in message
...
I want to open a workbook, update the data from Access
using MS Query, then saveas the workbook with a new name.
Excel wants to run the sub without waiting for the
refreshed data.

Is there any way to get the VBA to recognise that the
refresh has finished and then continue with sub?