Open the most recent folder in a directory
<p>I'm trying to create a script that will open the latest folder in a directory. </p>

<p>The name of the folder will be different each month (01-Jan, 02-Feb e.t.c). The below seems to find the latest folder, but I get error File not found when I add in Shell "explorer.exe" &amp; "" &amp; strFullFldrPath, vbNormalFocus to open the folder.</p>

<p>This is what I have so far.</p>

<pre><code>Sub GetLatestFolder()

Dim fso As FileSystemObject
Dim fldrRoot As Folder
Dim SubFld As Folder

Dim strFolderName As String
Dim strFullFldrPath As String


Set fso = New FileSystemObject
Set fldrRoot = fso.GetFolder("\\Hbeu.adroot.hsbc\dfsroot\GB002\RRU\DTCC EU Reports\ETD\")

For Each SubFld In fldrRoot.SubFolders
strFolderName = SubFld.Name
strFullFldrPath = fldrRoot &amp; "\" &amp; SubFld.Name

Shell "explorer.exe" &amp; "" &amp; strFullFldrPath, vbNormalFocus
    Exit For
Next SubFld

End Sub
</code></pre>