Thanks Glenn, really appreciate the help so far!

What I intend doing is running this script as a scheduled task once a week to randonly pull out the required number of entries from my file. What sometimes may happen is that the extract may contain only 4 entries, but my "picker" will normally be set for 5.

I am going to use the "alternate loop" code above, and make the following additions:
 Code:
$Size = Ubound($Array)
$Size + 1 ' elements were loaded' ?	; show element count
$SizeTotal = $Size + 1
$SizeTotal ?

If $SizeTotal =< $Pick
	"Entries in file less than or equal to $PICK" ?
	Sleep 3
	Exit
EndIf


What I also noticed is that the entries picked don't appear to be that "random"

for example,
My file with:
Widget1
Wigdet2
Widget3
Widget4
Widget5

and pick of 2 always gives me
Widget1
Widget2

Thought it would be a bit more random than that...

Thanks heaps for all you help so far. \:\)


Edited by Willmaykett (2008-12-15 09:29 AM)
Edit Reason: Made changes to code