1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
public string getRandomPassword()
{
#region regDef
Random rndNr = new Random();
#endregion
try
{
string[] nums = { "123", "234", "345", "456", "567", "678", "789", "987", "876", "765", "654", "543", "432", "321", "111" };
return "Start" + nums[rndNr.Next(0, nums.Length)]; //Passwort zusammensetzen und zurückgeben, z.B. Start789
}
catch (Exception ex)
{
//ErrorHandling
}
}
|