Solved

Get Current User's My Document's My Pictures Folder

Posted on 2007-12-06
3
422 Views
Last Modified: 2010-04-21
Is it possible to get the current user's My pictures Folder?
C:\Documents and Settings\@CurrentUser@\My Documents\My Pictures

This is for a windows service to copy files from this directory to a network share.  The service is setup to run on LocalSystem, would this also need to be changed?

I am trying to be able to install this windows service without having to hardcode the user's my pictures path.
0
Comment
Question by:JRockFL
3 Comments
 
LVL 19

Expert Comment

by:Delphineous Silverwing
ID: 20424942
Look at Microsoft Knowledge Base article 274443 about using Group Policies for redirecting these folders.
http://support.microsoft.com/kb/274443/en-us
0
 
LVL 3

Accepted Solution

by:
SLFuqua earned 500 total points
ID: 20425022
I don't have VB on this machine, but you can create a variable (e.g., myPath) and assign it "= my." and when you type the dot a whole list of possibilities open up.

I can get the exact code in the morning when I get to work if you need.

Best,
sl
0
 
LVL 8

Author Closing Comment

by:JRockFL
ID: 31413319
Thank you!
My.Computer.FileSystem.SpecialDirectories.MyPictures
0

Featured Post

Is Your AD Toolbox Looking More Like a Toybox?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question