Results 1 to 4 of 4

Thread: Getting the user's application folder

  1. #1

    Thread Starter
    Member
    Join Date
    Mar 2002
    Posts
    40

    Getting the user's application folder

    Hi,

    I'm trying to retrieve the user's application folder. Normally I'll retrieve the folder from the registry in HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders

    My question is, is there any .NET Framework class that can do the same job?

    Thanks in advance.

  2. #2
    Frenzied Member DevGrp's Avatar
    Join Date
    Nov 2001
    Location
    Charlotte, NC
    Posts
    1,256
    What folder are you talking about?

    If its the folder that the program is in, then its Environment.CurrentDirectory
    Dont gain the world and lose your soul

  3. #3
    Frenzied Member Jop's Avatar
    Join Date
    Mar 2000
    Location
    Amsterdam, the Netherlands
    Posts
    1,986
    You can use the system.Enviroment to do this:

    VB Code:
    1. MessageBox.Show(System.Environment.GetFolderPath(System.Environment.SpecialFolder.LocalApplicationData))

    Check out all the members of the System.Enviroment.SpecialFolder.. this is an enum for all the special folders.
    Jop - validweb.nl

    Alcohol doesn't solve any problems, but then again, neither does milk.

  4. #4

    Thread Starter
    Member
    Join Date
    Mar 2002
    Posts
    40
    Thanks

Posting Permissions

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



Click Here to Expand Forum to Full Width