Sign in to follow this  
Followers 0
chiners_68

can somome correct why this variable dosent work..

4 posts in this topic

I ve got the following to copy files from the current logged on users profile to the all users profile but it dosent work. can somone correct what needs correcting in my lines to make the variable work.

if i uses my usnername instead of the variable the lines work fine. its just adding in the variable that hasnt worked.

FileCopy("@ProgramsDir\Paint Shop Pro 5\*.*", "C:\Documents and Settings\All Users\Start Menu\Programs\Paint Shop Pro 5\")

FileCopy("@ProgramsDir\Paint Shop Pro 5\Paint Shop Pro 5.lnk", "C:\Documents and Settings\All Users\desktop\")

Share this post


Link to post
Share on other sites



Try

FileCopy(@ProgramsDir & "\Paint Shop Pro 5\*.*", "C:\Documents and Settings\All Users\Start Menu\Programs\Paint Shop Pro 5\")
FileCopy(@ProgramsDir & "\Paint Shop Pro 5\Paint Shop Pro 5.lnk", "C:\Documents and Settings\All Users\desktop\")


Get Beta versions Here Get latest SciTE editor Here AutoIt 1-2-3 by Valuater - A great starting point.

Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Share this post


Link to post
Share on other sites

"C:\Documents and Settings\All Users\desktop" --> @DesktopCommonDir

"C:\Documents and Settings\All Users\Start Menu\Programs" --> @ProgramsCommonDir

:D

Share this post


Link to post
Share on other sites

what tittoproject is pointing out to you would look like:

FileCopy(@ProgramsDir & "\Paint Shop Pro 5\*.*", @ProgramsCommonDir & "\Paint Shop Pro 5\")
FileCopy(@ProgramsDir & "\Paint Shop Pro 5\Paint Shop Pro 5.lnk", @DesktopCommonDir)

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0