Click or drag to resize

RandomUInt32Between Method

Generates a cryptographically strong unsigned 32-bit random integer between specified values. i.e. [startNumber-stopNumber)

Namespace: GSF.Security.Cryptography
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.297-beta+c4c8a839e939f7741977e6b01208d8a074273105
Syntax
public static uint UInt32Between(
	uint startNumber,
	uint stopNumber
)
View Source

Parameters

startNumber  UInt32
A UInt32 that is the low end of our range.
stopNumber  UInt32
A UInt32 that is the high end of our range.

Return Value

UInt32
A UInt32 that is generated between the startNumber and the stopNumber.
Exceptions
ExceptionCondition
CryptographicExceptionThe cryptographic service provider (CSP) cannot be acquired.
See Also