Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default Using FoundFiles to list by path and filename

I am using a macro that lists files that are in the directory I choose
via browseforfolder. The founfiles function lists files
alphabetically, regardless of which subfoler it is in. Is there a way
to get a list of files in a folder to appear alphabetically, and then
continue the list with files in the first subfolder and so on?

for example, if i have a folder called 'pictures' that has sub folders
'home' and 'vacation' I would want all the files in 'pictures' to be
listed, then the files in 'home', then the files in 'vacation'. Thanks
for any help/advice you can give.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default Using FoundFiles to list by path and filename

figured it out, i just did a sort ascending command. works like a
champ.

range("B9:F" & count + 9).Select
Selection.Sort Key1:=range("B9"),
Order1:=xlAscending, Header:=xlGuess, OrderCustom:=1, MatchCase:=False,
Orientation:=xlTopToBottom, DataOption1:=xlSortNormal

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Using FoundFiles to list by path and filename

If you are going to put them in a worksheet, why not put them in the
worksheet and sort them.

--
Regards,
Tom Ogilvy

"Jon" wrote in message
oups.com...
I am using a macro that lists files that are in the directory I choose
via browseforfolder. The founfiles function lists files
alphabetically, regardless of which subfoler it is in. Is there a way
to get a list of files in a folder to appear alphabetically, and then
continue the list with files in the first subfolder and so on?

for example, if i have a folder called 'pictures' that has sub folders
'home' and 'vacation' I would want all the files in 'pictures' to be
listed, then the files in 'home', then the files in 'vacation'. Thanks
for any help/advice you can give.



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
http://CannotDeleteFile.net - Cannot Delete File? Try Long Path ToolFilename is too long? Computer Complaining Your Filename Is Too Long? TheLong Path Tool Can Help While most people can go about their businessblissfully unaware of the Windo Max Loger Excel Discussion (Misc queries) 0 June 14th 11 04:30 PM
Using .FoundFiles to list files by path and file name Jon[_21_] Excel Programming 0 April 12th 06 04:45 AM
Pulling in the path to a filename Pradhan Excel Worksheet Functions 5 November 8th 05 02:36 AM
Filename and path Mike Excel Programming 1 October 19th 05 07:33 PM
How to import a path/filename when importing data into an XML list cxparker Excel Worksheet Functions 0 December 7th 04 10:13 PM


All times are GMT +1. The time now is 08:23 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"