Yep. And the use of writeline instead of redirectoutput will also prevent any unwanted info the end up in the output file. Using writeline you can just write the stuff you want instead of dumping all output to a file.

Putting an index in a for each loop is quite easy. Have a look at the example below.

Code:

Break on
$test = Split ("1~2~3~4~5~6~7~8~9~0","~")
$index = 0
For Each $number in $test
$index = $index + 1
?"Index: " + $index + " Number: " + $number
Next
Sleep 5



Edited by Mart (2005-12-28 07:33 PM)
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.