GetTrulyRandom() 공개 정적인 메소드

public static GetTrulyRandom ( ) : Random
리턴 System.Random
예제 #1
0
        public static string RandomString(bool guid = false)
        {
            string res = "";
            Random rg  = Utils.GetTrulyRandom();

            for (int i = 0; i < rg.Next(3, 7); i++)
            {
                res += (char)rg.Next((int)'A', (int)'Z' + 1);
            }

            if (guid)
            {
                res += rg.Next(1000, 100000);
            }
            return(res);
        }
예제 #2
0
        public static string RandomLetter()
        {
            Random rg = Utils.GetTrulyRandom();

            return(((char)rg.Next((int)'A', (int)'Z' + 1)).ToString());
        }