Solved

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

Posted on 2007-12-06
3
441 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

738 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