My Documents / Program File Directories

  • Thread starter Thread starter Shawn Mehaffie
  • Start date Start date
S

Shawn Mehaffie

I have an application I want to be able to:

1) Store user specifc settings in ther "My Documents".

2) Store some information in "All Users" document directory.

3) I also want to be able to access program files that are installed in the
"Program Files" directory.

How can I get these locations from within a VB application.

S. Shawn Mehaffie
 
Hi,

Debug.WriteLine(Environment.GetEnvironmentVariable("ALLUSERSPROFILE"))

Debug.WriteLine(Environment.GetFolderPath(Environment.SpecialFolder.Personal
))

Debug.WriteLine(Environment.GetFolderPath(Environment.SpecialFolder.ProgramF
iles))



Ken
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top