Jump to content

Recommended Posts

Posted (edited)

I've searched and searched and tried different things through the help file. I'm such a noob I'm sure its simple, but heres what I'm trying to do...

my wedding is in one week and for grooms gifts I gave my guys dvd burners, i also got them programs to burn stuff with them.

They are all VERY basic computer users so simple things like copying files from the cd to a folder would be something i couldn't even walk them through on the phone.

so I tried to create a cd that has all the programs and my scripts on it... I want them to be able to just run one exe I created that will copy all the files needed from the cd to the proper directory. The problem I'm having is i cant seem to create a script that will simply move everything from the cd to a specified directory...

It would then call up another script that was just moved that would install everything..

I think my problem is the @AutoItExe part, If i understood right, and im sure i didn't, thats the macro that will call up the directory that this script is running from, so if i have one guy with his cd drive as D:and one with his as G: it would still work. I figured a filecopy of *.* wouldn't be good because this script would be on the disc as well...

this is what i have so far

DirCreate("C:\groomsmen")

filecopy( @AutoItExe & "\Programs\*.*", "C:\groomsmen\")

filecopy( @AutoItExe & "\scripts\next.exe", "C:\groomsmen\")

filecopy( @AutoItExe & "\scripts\now.exe", "C:\groomsmen\")

filecopy( @AutoItExe & "\scripts\later.exe", @DesktopDir)

any help would be greatly appeciated

Edited by ounelly70
Posted

Instead of @AutoItExe try using @ScriptDir


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

Posted

This should do the trick!

DirCreate("C:\groomsmen")
filecopy(  @scriptdir & "\Programs\*.*", "C:\groomsmen\")
filecopy(  @scriptdir & "\scripts\next.exe", "C:\groomsmen\")
filecopy(  @scriptdir & "\scripts\now.exe", "C:\groomsmen\")
filecopy(  @scriptdir & "\scripts\later.exe", @UserProfileDir&"\desktop")

Good luck with the wedding!

Posted

Im a cock today - @DesktopDir will work just fine!

He is copying the files from the CD to a folder on the C drive. @DesktopDir would be of no use to him. :D


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

  • Moderators
Posted

Congratulations ounelly70, but you better put AutoIt down now before the wedding, or you may be programming right through it :D

One thing to keep in mind, don't hard code drives, if you want it to be their main drive, then look at the macro @HomeDrive:

Example.

DirCreate(@HomeDrive & "\groomsmen")
"C:\" although popular is not always "everyones" main drive.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Posted

Congratulations ounelly70, but you better put AutoIt down now before the wedding, or you may be programming right through it :D

One thing to keep in mind, don't hard code drives, if you want it to be their main drive, then look at the macro @HomeDrive:

Example.

DirCreate(@HomeDrive & "\groomsmen")
"C:\" although popular is not always "everyones" main drive.

awesome, thanks! I didnt even know you could do that part! :D

Posted

Really guys, thanks a bunch, i just tried everything and it all works perfectly! autoit really has to be the best thing out there, with the best help too.

Posted

Forgot to say welcome to the forums and good luck with the wedding. :D:D


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

Posted

thanks guys, im excited :D

I do have another quick question though, how would i go about exiting a program thats running in the system tray just once with autoit ?

again any help is greatly appreciated, and you guys are great at it!

Posted

Then they will try to figure out how to script their spouse to get them a beer without saying anything to them.

:D

A good wife does not need a script to know when to get their man a beer. :D:P;)


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

Posted

thanks guys, im excited :D

I do have another quick question though, how would i go about exiting a program thats running in the system tray just once with autoit ?

again any help is greatly appreciated, and you guys are great at it!

If it is an AutoIt program that you have scripted you could add a Hotkey to it. If it is not lookup ProcessClose in the help file.


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

Posted

If it is an AutoIt program that you have scripted you could add a Hotkey to it. If it is not lookup ProcessClose in the help file.

thanks so much

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...