Integer and string conversion

When processing the water, it is generally necessary to convert the corresponding integers to a string of the corresponding number of digits.

        /// <summary>        ///Convert the integer to the string of the specified bit/// </summary>        /// <param name="slen">A number of digits (the maximum 32 digits here)</param>        /// <param name="maxSN">Integer</param>        /// <returns></returns>        public string setSN(int slen, int maxSN)        {            string sn = "00000000000000000000000000000000";            sn = sn.Substring(0, slen - (maxSN + 1).ToString().Length) + (maxSN + 1).ToString();            if (maxSN.ToString().Length >= slen)            {                sn = maxSN.ToString();            }            return sn;        }