VBA/Excel/Access/Word/File Path/CurDir
CurDir() Returns a string representing the current drive path.
<source lang="vb">
Sub strDemo20()
Debug.Print CurDir()
End Sub
</source>
To return the current path for a specified drive
<source lang="vb">
Sub curDirDemo1()
CurDir ("C:\")
End Sub
</source>
To return the current path, use CurDir without an argument:
<source lang="vb">
Sub curDirDemo()
MsgBox CurDir
End Sub
</source>