function checkLen(str) {
            var num = parseInt(str);
            var num1 = parseInt(document.getElementById(str).value);
            var maxLen = parseInt(document.getElementById(str).maxLength);

            var numChars = 1;
            while (num1 > 10) {
                num1 = num1 / 10;
                numChars++;
            }
            
            if (numChars == maxLen) {
                document.getElementById(num).blur();
                num = num + 1;
                num = num + '';
                document.getElementById(num).focus();
            }
        }
