예제 #1
0
        /// <summary>
        /// 获取16位随机字符串
        /// </summary>
        /// <returns></returns>
        public static string GetNoncestr(int length)
        {
            var random = new Random();

            return(MD5UtilHelper.GetMD5(random.Next(1000).ToString(), "GBK").Substring(0, length));
        }
예제 #2
0
        /// <summary>
        /// 获取随机字符串
        /// </summary>
        /// <returns></returns>
        public static string GetNoncestr()
        {
            Random random = new Random();

            return(MD5UtilHelper.GetMD5(random.Next(1000).ToString(), "GBK"));
        }