Solved

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

Posted on 2007-12-06
3
406 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

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

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…
Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

757 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now