IMcOMGlobalMcRand Method
|
|
Generates an array of random numbers with values between 0 and
32768
Namespace:
MediaCy.IQL.ObjectManager
Assembly:
MediaCy.IQL.ObjectManager (in MediaCy.IQL.ObjectManager.dll) Version: 10.0.6912.0
SyntaxFunction McRand (
Optional lNofResults As Integer = 1,
Optional lSeed As Integer = 0
) As McObject
Parameters
- lNofResults (Optional)
- Type: SystemInt32
Number of random values to return (1 by default). - lSeed (Optional)
- Type: SystemInt32
A seed value. A value of 1 reinitializes the sequence.
Return Value
Type:
McObjectA McObject holding a single random number if lNofResults is not given
or is 1. Otherwise returns an McObject holding a 1-D array of Long values
containing random numbers, with the length determined by the value of Arg0.
HRESULT
RemarksTo generate the same sequence of random numbers repeatedly,
re-seed the sequence generator with McRand(, 1). Random values are
uniformly distributed in the range from 0 to 32768 (&H7FFF&, which is the
largest value that a VB Integer can hold).
See Also