I came across a little quirk when using the Random() function. If Min and Max are the same value, then Random() returns 0 rather than the Min/Max value. The Flag does not make any difference. For example, the following returns 0 for all four "tests" MsgBox(0, "test 1", Random(1, 1, 1)) MsgBox(0, "test 2", Random(2, 2, 1)) MsgBox(0, "test 3", Random(3, 3, 1)) MsgBox(0, "test 4", Random(4, 4, 0)) I am using the following workaround for the time being. Func FixRandom($min, $max, $flag=0)