ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Export folder/file listings from Windows Explorer to Excel/Word. (https://www.excelbanter.com/excel-programming/373140-export-folder-file-listings-windows-explorer-excel-word.html)

CandiceMyers

Export folder/file listings from Windows Explorer to Excel/Word.
 
I would like to be able to take a file/folder listing from Windows Explorer
and copy it into Excel or Word.

----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm...el.programming

Jim Cone

Export folder/file listings from Windows Explorer to Excel/Word.
 
The free Excel add-in "List Files" will do that.
Download from ... http://www.realezsites.com/bus/primitivesoftware
No registration required.
--
Jim Cone
San Francisco, USA


"CandiceMyers"

wrote in message
I would like to be able to take a file/folder listing from Windows Explorer
and copy it into Excel or Word.

Kevin B

Export folder/file listings from Windows Explorer to Excel/Word.
 
In the event that Microsoft does not get around to your request, here's a
small macro that will do that for you. Just change the path in the DIR
command to the directory you want the files listed from:

Sub PostFileNames()

Dim strDir As String
Dim strFile As String
Dim lngRow As Long

ActiveWorkbook.Worksheets("Sheet1").Activate
Range("A1").Select
strDir = "C:\*.*"
strFile = Dir(strDir)

Do While strFile < ""
ActiveCell.Offset(lngRow).Value = strFile
lngRow = lngRow + 1
strFile = Dir
Loop

End Sub
--
Kevin Backmann


"CandiceMyers" wrote:

I would like to be able to take a file/folder listing from Windows Explorer
and copy it into Excel or Word.

----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm...el.programming


Ron de Bruin

Export folder/file listings from Windows Explorer to Excel/Word.
 

Hi CandiceMyers

If you use local folders this is a way for the folder C:\Data to copy to a txt file

Shell "CMD /C DIR C:\data\ /B /S C:\MYFILES.TXT"
Shell "notepad.exe C:\MYFILES.txt", vbNormalFocus

Check out also this way
http://support.microsoft.com/default...EN-US;q272623&

You can change it to this to display the txt file and not print

@echo off
dir %1 /-p /b /o:gn /s "%temp%\Listing.txt"
start notepad "%temp%\Listing.txt"
exit



--
Regards Ron de Bruin
http://www.rondebruin.nl



"CandiceMyers" wrote in message ...
I would like to be able to take a file/folder listing from Windows Explorer
and copy it into Excel or Word.

----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm...el.programming





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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com