defaulting to my documents folder

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Mong

    #1

    defaulting to my documents folder

    Hi,

    I have an application which has several hard coded references to
    "C:\My Documents". Shortly our network setup will be changed so that a
    users My Documents folder will be on a mapped network home drive, and
    nothing will be written to the local C:.

    So my question is, how do I explicitly code the path to the users My
    Documents folder so that it will use it no matter where it's sitting
    (whether it be on C: or a network drive)?

    ie instead of "C:\My Documents\" something like "My Documents\"

    Thanks in advance,

    Mong
  • TC

    #2
    Re: defaulting to my documents folder

    Google on:

    CSIDL_PERSONAL VBA

    This will lead you to code that gets the pathname of the current user's My
    Documents folder (where-ever that folder may be).

    HTH,
    TC


    "Mong" <mongphong28@ya hoo.com.au> wrote in message
    news:47a140d4.0 310281840.15d47 9b4@posting.goo gle.com...[color=blue]
    > Hi,
    >
    > I have an application which has several hard coded references to
    > "C:\My Documents". Shortly our network setup will be changed so that a
    > users My Documents folder will be on a mapped network home drive, and
    > nothing will be written to the local C:.
    >
    > So my question is, how do I explicitly code the path to the users My
    > Documents folder so that it will use it no matter where it's sitting
    > (whether it be on C: or a network drive)?
    >
    > ie instead of "C:\My Documents\" something like "My Documents\"
    >
    > Thanks in advance,
    >
    > Mong[/color]


    Comment

    • Mong

      #3
      Re: defaulting to my documents folder

      Thanks for that, but I'm just wondering is API the only way?

      Was hoping I wouldn't have to add too much code as I won't be the one
      looking after the app, most probably the user will so I don't want to
      over complicate it.



      "TC" <a@b.c.d> wrote in message news:<106739978 7.554381@teutho s>...[color=blue]
      > Google on:
      >
      > CSIDL_PERSONAL VBA
      >
      > This will lead you to code that gets the pathname of the current user's My
      > Documents folder (where-ever that folder may be).
      >
      > HTH,
      > TC
      >
      >
      > "Mong" <mongphong28@ya hoo.com.au> wrote in message
      > news:47a140d4.0 310281840.15d47 9b4@posting.goo gle.com...[color=green]
      > > Hi,
      > >
      > > I have an application which has several hard coded references to
      > > "C:\My Documents". Shortly our network setup will be changed so that a
      > > users My Documents folder will be on a mapped network home drive, and
      > > nothing will be written to the local C:.
      > >
      > > So my question is, how do I explicitly code the path to the users My
      > > Documents folder so that it will use it no matter where it's sitting
      > > (whether it be on C: or a network drive)?
      > >
      > > ie instead of "C:\My Documents\" something like "My Documents\"
      > >
      > > Thanks in advance,
      > >
      > > Mong[/color][/color]

      Comment

      • TC

        #4
        Re: defaulting to my documents folder

        Maybe there is something available from Windows Scripting Host? (if the
        users will have WSH on their PCs)

        HTH,
        TC


        "Mong" <mongphong28@ya hoo.com.au> wrote in message
        news:47a140d4.0 310301726.11bb7 c84@posting.goo gle.com...[color=blue]
        > Thanks for that, but I'm just wondering is API the only way?
        >
        > Was hoping I wouldn't have to add too much code as I won't be the one
        > looking after the app, most probably the user will so I don't want to
        > over complicate it.
        >
        >
        >
        > "TC" <a@b.c.d> wrote in message news:<106739978 7.554381@teutho s>...[color=green]
        > > Google on:
        > >
        > > CSIDL_PERSONAL VBA
        > >
        > > This will lead you to code that gets the pathname of the current user's[/color][/color]
        My[color=blue][color=green]
        > > Documents folder (where-ever that folder may be).
        > >
        > > HTH,
        > > TC
        > >
        > >
        > > "Mong" <mongphong28@ya hoo.com.au> wrote in message
        > > news:47a140d4.0 310281840.15d47 9b4@posting.goo gle.com...[color=darkred]
        > > > Hi,
        > > >
        > > > I have an application which has several hard coded references to
        > > > "C:\My Documents". Shortly our network setup will be changed so that a
        > > > users My Documents folder will be on a mapped network home drive, and
        > > > nothing will be written to the local C:.
        > > >
        > > > So my question is, how do I explicitly code the path to the users My
        > > > Documents folder so that it will use it no matter where it's sitting
        > > > (whether it be on C: or a network drive)?
        > > >
        > > > ie instead of "C:\My Documents\" something like "My Documents\"
        > > >
        > > > Thanks in advance,
        > > >
        > > > Mong[/color][/color][/color]


        Comment

        Working...