View Single Post
 
Old 05-18-2016, 08:32 PM
gmayor's Avatar
gmayor gmayor is offline Windows 10 Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,144
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Perhaps the simplest solution is the Printfolders utility which you can download from my web site - http://www.gmayor.com/downloads.htm

Alternatively you could use a macro. The following is the most basic
Code:
Option Explicit

Sub ListFiles()
Dim strFile As String
Const strPath As String = "C:\Path\" 'The folder to process
Dim strList As String
    strFile = Dir$(strPath & "*.*")
    While strFile <> ""
        strList = strList & strFile & vbCr
        strFile = Dir$()
    Wend
    strList = Left(strList, Len(strList) - 1)
    Selection.Text = strList
lbl_Exit:
    Exit Sub
End Sub
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote