Home > Forum Home > Analyzing Corporate Financial Data > VBA Application.Filesearch workaround > The DIR function Share

The DIR function

Excel Help for The Dir Function in Analyzing Corporate Financial Data


Forum TopicLogin

The Dir Function

Rate this:
(3/5 from 1 vote)
HappyYou can loop through files in a directory using the Dir function:
VBA Code:
Sub LoopThroughXLS()
    Dim sFName As String
    sFName = Dir(”*.xls”)
    Do While Len(sFName) > 0
        Debug.Print sFName
        sFName = Dir
    Loop
End Sub

 Excel Business Forums Administrator
 Posted by on
 
View Full Post

Excel templates and solutions matched for The DIR function:

Solutions: Technical Analysis Functions PowerPoint Integration