Posts

Showing posts with the label C#

C# Generate Random String of a Specific Length

The following function will generate a random string of the supplied length.  The function uses the Random object to generate random integer values that correspond to ASCII values within a specific range (a-z, 0-9).  Once a random string has been generated that is the required length, it is then returned.