Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2004
    Location
    austin
    Posts
    146

    Unanswered: My Documents Folder

    how can i get the path to the My Documents folder across different windows platforms?

  2. #2
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    For what purpose? The path to my documents is always "C:\Documents and Settings\CurrentUserNameGoesHere\My Documents". Maybe the current user name is what you really need to find?
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  3. #3
    Join Date
    Jan 2004
    Location
    austin
    Posts
    146
    i'm printing pdf files to the folder and some people are on 2k and some are on XP.
    Last edited by michelin man; 11-28-05 at 14:34.

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    So if you pull the network userid from a system object or API call you can then build your path as required

    HTH

  5. #5
    Join Date
    Mar 2005
    Posts
    261
    You can't guarantee the path won't change on different OS or in different languages. Therefore you shouldn't hard code the path.

    Instead consider this:

    Code:
    Set objShell = CreateObject("WScript.Shell")
    strMyDocsPath = objShell.SpecialFolders("MyDocuments")
    Set objShell = Nothing

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •