Whatever message this page gives is out now! Go check it out!
RandRange(number1, number2[, algorithm])Parameter | Description |
number1, number2 | Integer numbers. If the numbers are not in the range -2,147,483,648 - 2,147,483,647, ColdFusion generates an error. |
algorithm | (Optional) The algorithm to use to generate the random number. ColdFusion installs a cryptography library with the following algorithms:
|
<cfscript>
num1 = -100000;
num2 = 100000;
randAlgorithmArray = ["CFMX_COMPAT", "SHA1PRNG", "IBMSecureRandom"];
for(index = 1; index <= arrayLen(randAlgorithmArray); index++)
{
WriteOutput("The rand number in the range #num1# to #num2# using #randAlgorithmArray[index]# is: "
& randRange(num1, num2, randAlgorithmArray[index]) & "<br/>");
}
</cfscript>