LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default VBA to run queries in 5 different worksheets


hi there,

I've got a bit of a complex problem I need help with.
I have to write some VBA that will do the following in one go:

1. Refresh a query containing a list of names
2. On 5 worskheets I have queries that incoporate a name in the where
clause.
3 For each name returned in the refreshed query in 1. refrsh all 5
worksheets using that name in the whereclause
4. once all 5 worksheets have been refreshed, save the entire
spreadsheet as <name.xls


right, thats it in a nutshell.
I need to know where to type this VBA.
I'm not sure when modules are used etc.

I need to know how to refresh the query on the first sheet (producing
the names)
and then I need to know how to use each name to refresh the 5
subsequwnt worksheets.

any help you can offer is appreciated.
I've got a vague idea about it. but haven't a clue where to start
typing the code, and how to organise the code....

thanks in advance,
Matt


--
matpj
------------------------------------------------------------------------
matpj's Profile: http://www.excelforum.com/member.php...o&userid=21076
View this thread: http://www.excelforum.com/showthread...hreadid=472083

 
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
Web Queries Stonewall Excel Discussion (Misc queries) 4 July 23rd 07 03:35 PM
web queries... Dave F Excel Discussion (Misc queries) 2 August 25th 06 02:15 AM
How do I combine two queries from different worksheets Jez838 New Users to Excel 1 January 11th 06 02:31 PM
Using Excel Worksheets like Access Queries Lab Dude Links and Linking in Excel 2 August 12th 05 01:26 PM
Web Queries Alistair[Data#3] Excel Discussion (Misc queries) 0 May 20th 05 12:39 AM


All times are GMT +1. The time now is 08:21 AM.

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

About Us

"It's about Microsoft Excel"