Generation of random alphanumeric string in C#
The following code snippet shows how to generate random alphanumeric string in C#.
using System;
using System.Text;
public string RandomString (Random r, int len)
{
string str
= "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890";
StringBuilder sb = new StringBuilder();
while ((len--)> 0)
sb.Append(str[(int)(r.NextDouble() * str.Length)]);
return sb.ToString();
}
HI
Shanthi M
Can you please check this link.....
http://www.eggheadcafe.com/software/aspnet/30271254/c-random-alphanumeric-st.aspx
If you copied some one code , provide link....
Thanks
Dontworry