Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Open next excel file in directory and stop when no more files

Hi Eric

There is a filter example on the copy3 page


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Eric_G" wrote in message ...
Ron,

One more question... How do I copy just the "filtered rows" in the initial
excel file rather than the whole file? These rows are then to be pasted into
another file (one single file) one after another until all the filtered rows
in each file in the sub-directory have been copied over.

Thank you in advance.

"Ron de Bruin" wrote:

Hi Eric

With Ctrl End you can jump to the last cell on a worksheet
Maybe there is something in a cell below your data that you not know.

Always test with a few files in a folder first
If you use the Add-in you can check the log file for the range


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Eric_G" wrote in message ...
Ron,
The macro worked BUT FOR the fact that I received the error mesasge
indicating that there weren't enough rows available in the new file. It
would appear that the macro is going back and starting again from the
beginning of the files listed in the directory and creating another listing
of all the underlying files. Any ideas?

"Ron de Bruin" wrote:

Hi Eric

See
http://www.rondebruin.nl/copy3.htm

Maybe you like the add-in
http://www.rondebruin.nl/merge.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Eric_G" wrote in message ...
I would like to invoke a macro to open the "first" EXCEL file in a directory
(and I don't care if "first" means by alpha name, first by date, etc.), copy
the filtered data file contents to another file (file 2) and then close the
first file, then open the next file in the directory and do the same (i.e.
copy the filtered data file contents to file 2), and so.

How do I specify the "first" file in the listing and then how do I specify
"open the next file" and continue doing so until there are no more files
which have been opened?

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
How do I set up an Excel 2007 default directory for a File Open? Lynn Excel Discussion (Misc queries) 1 April 15th 08 05:30 PM
Excel Slow File Open Directory Response Dave P Excel Discussion (Misc queries) 0 September 30th 05 01:37 AM
How do I stop Excel from closing the open file each time I open a. Welsin Setting up and Configuration of Excel 3 January 8th 05 11:16 PM
Directory List of Excel Files No Name Excel Programming 6 May 18th 04 05:22 PM


All times are GMT +1. The time now is 03:07 PM.

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"