Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Saving one table in different xls files

Status
Not open for further replies.

Catoal

Technical User
Feb 15, 2005
13
0
0
BE
Hi,

I've got a db with more than 500000 records. Each record is associated with a group number. I've got 200 different groups. I would like to export each group separately in different files(1 by group) xls or other format.

Is it possible to do that with a macro or a module?
Could yo uhelp me?
 
Take a look at the DoCmd.TransferSpreadSheet method.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
I've tried this method but it doesn't split my data!
I can create a query that select only one group but as I run my macro it only overwrite my previous file instead of creating a new!

Something else?
 
Get rid with macro and play with VBA.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Arguments are the same in vba for this command!!!
 
In VBA you can looping the group number and dynamically assign the spreadsheet name.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Great that's what I want!
How to do that?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top