Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Copy sheet from multiple files

Hello. I have a folder that has multiple files. I need several of the
files, but not all. Each file has only 1 sheet in it.

I would like to use multiselect to choose the files I need, and copy the
sheet from each of the selected files into a single file. So for example,
if I chose 7 files, my master file would have 7 sheets in it.

Thanks!


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default Copy sheet from multiple files

Is this what you are looking for?

http://www.rondebruin.nl/copy3.htm#sheet


"Steph" wrote in message
...
Hello. I have a folder that has multiple files. I need several of the
files, but not all. Each file has only 1 sheet in it.

I would like to use multiselect to choose the files I need, and copy the
sheet from each of the selected files into a single file. So for example,
if I chose 7 files, my master file would have 7 sheets in it.

Thanks!




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Copy sheet from multiple files

Close. That will give me all files...The folder I am eccessing has hundreds
of files. I need 20 or so. So I would like to incorporate the multi-select
into that, and that would be perfect!

"Barb Reinhardt" wrote in message
...
Is this what you are looking for?

http://www.rondebruin.nl/copy3.htm#sheet


"Steph" wrote in message
...
Hello. I have a folder that has multiple files. I need several of the
files, but not all. Each file has only 1 sheet in it.

I would like to use multiselect to choose the files I need, and copy the
sheet from each of the selected files into a single file. So for

example,
if I chose 7 files, my master file would have 7 sheets in it.

Thanks!






  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Copy sheet from multiple files

Basic code would be:

Dim v as Variant, i as Long, bk as workbook
v = Application.GetOpenFilename( Multiselect:=True)
if not isarray(v) then exit sub
for i = lbound(v) to ubound(v)
set bk = Workbooks.Open(v(i))
bk.Worksheets(1).Copy After:=ThisWorkBook.Sheets( _
ThisWorkbook.Sheets.count)
bk.Close SaveChanges:=False
Next

--
Regards,
Tom Ogilvy



"Steph" wrote in message
...
Hello. I have a folder that has multiple files. I need several of the
files, but not all. Each file has only 1 sheet in it.

I would like to use multiselect to choose the files I need, and copy the
sheet from each of the selected files into a single file. So for example,
if I chose 7 files, my master file would have 7 sheets in it.

Thanks!




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default Copy sheet from multiple files

I had to do something not long ago where I had a list of the path name and
the file name in an Excel workbook and needed to get other info out of the
document. This was the thread with the question and answers. It may help
you.
http://www.microsoft.com/office/comm...4-0666e4f15155


"Steph" wrote in message
...
Close. That will give me all files...The folder I am eccessing has
hundreds
of files. I need 20 or so. So I would like to incorporate the
multi-select
into that, and that would be perfect!

"Barb Reinhardt" wrote in message
...
Is this what you are looking for?

http://www.rondebruin.nl/copy3.htm#sheet


"Steph" wrote in message
...
Hello. I have a folder that has multiple files. I need several of the
files, but not all. Each file has only 1 sheet in it.

I would like to use multiselect to choose the files I need, and copy
the
sheet from each of the selected files into a single file. So for

example,
if I chose 7 files, my master file would have 7 sheets in it.

Thanks!










  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Copy sheet from multiple files

Thank you!

"Tom Ogilvy" wrote in message
...
Basic code would be:

Dim v as Variant, i as Long, bk as workbook
v = Application.GetOpenFilename( Multiselect:=True)
if not isarray(v) then exit sub
for i = lbound(v) to ubound(v)
set bk = Workbooks.Open(v(i))
bk.Worksheets(1).Copy After:=ThisWorkBook.Sheets( _
ThisWorkbook.Sheets.count)
bk.Close SaveChanges:=False
Next

--
Regards,
Tom Ogilvy



"Steph" wrote in message
...
Hello. I have a folder that has multiple files. I need several of the
files, but not all. Each file has only 1 sheet in it.

I would like to use multiselect to choose the files I need, and copy the
sheet from each of the selected files into a single file. So for

example,
if I chose 7 files, my master file would have 7 sheets in it.

Thanks!






Reply
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
Opening Multiple files and Copying the info all to one other sheet MsLucy Excel Discussion (Misc queries) 2 January 6th 06 05:41 PM
How do I edit a worksheet and copy to multiple files? artex Excel Discussion (Misc queries) 0 August 31st 05 11:08 PM
How do I pull data from multiple files and copy into one file JT Excel Programming 2 May 3rd 05 07:42 PM
Copy text files into multiple sheets of 1 workbook Steve[_56_] Excel Programming 0 January 14th 04 08:30 PM
Copy worksheet from multiple files in one DIR to another DIR & rename Mike Taylor Excel Programming 1 July 13th 03 03:28 PM


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

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

About Us

"It's about Microsoft Excel"