Getting the address of 'MyDocuments'

  • Thread starter Thread starter Michelle
  • Start date Start date
M

Michelle

Hello, I want to be able to refer to a user's 'MyDocuments' folder -
whatever operating system/network/etc. they are using.

Is there a way to refer to it that isn't dependant on their setup?

Thanks

M
 
I use:

Dim myDocumentsPath As String

myDocumentsPath = CreateObject("WScript.Shell") _
.SpecialFolders.Item("mydocuments")

MsgBox myDocumentsPath
 
Dave,

Thanks for the tip! I've used the environ("user") and put that in an
explicit path but like your suggestion.

I use:

Dim myDocumentsPath As String

myDocumentsPath = CreateObject("WScript.Shell") _
.SpecialFolders.Item("mydocuments")


John Keith
(e-mail address removed)
 
Back
Top