random string
public static string GetRandomString(int intSize)
{
StringBuilder strBuilder=new StringBuilder();
Random rndObject=new Random();
for (int IndCar=0; IndCar<intSize; IndCar++)
{
int intRandom=Convert.ToInt32(Math.Floor(26*rndObject.NextDouble()+65));
char carRandom=Convert.ToChar(intRandom);
strBuilder.Append(carRandom);
}
rndObject=null;
return strBuilder.ToString().ToLower();
}
{
StringBuilder strBuilder=new StringBuilder();
Random rndObject=new Random();
for (int IndCar=0; IndCar<intSize; IndCar++)
{
int intRandom=Convert.ToInt32(Math.Floor(26*rndObject.NextDouble()+65));
char carRandom=Convert.ToChar(intRandom);
strBuilder.Append(carRandom);
}
rndObject=null;
return strBuilder.ToString().ToLower();
}