Jump to content

please help with this loop.


Recommended Posts

$set = 10
For $i = 1 to $set

FileInstall(@DesktopDir & "key.exe",@DesktopDir & "key" & $i & ".exe",1)

Next

im trying to create key1.exe - key10.exe on my desktop and it does not seem to be working.

Edited by t0ddie

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Link to comment
Share on other sites

im trying to create key1.exe - key10.exe on my desktop and it does not seem to be working.

Three things:

1.) @DesktopDir return the path without trailing "\".

2.) You might want to use FileCopy instead of FileInstall

3.) Check error conditions after function call. See help file and @error

Cheers

Kurt

__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Link to comment
Share on other sites

excellent, now i see my mistake! lol

another question.. without opening a new thread.....

how do you check a number.. and determine whether its ODD or EVEN??

for $x = 1 to 10
if $x is even then.......
endif

if $x is odd then.......
endif
next

something like that

Edited by t0ddie

Valik Note Added 19 October 2006 - 08:38 AMAdded to warn level I just plain don't like you.

Link to comment
Share on other sites

how do you check a number.. and determine whether its ODD or EVEN??

METACODE:

if mod($x,2) = 0 then "EVEN"
else "ODD"

Cheers

Kurt

__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Link to comment
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
 Share

  • Recently Browsing   0 members

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