AssessmentAnywhere.Excel.AssessmentParser.ColToInt C# (CSharp) Method

ColToInt() public static method

public static ColToInt ( string columnRef ) : int
columnRef string
return int
        public static int ColToInt(string columnRef)
        {
            if (string.IsNullOrEmpty(columnRef))
            {
                throw new ArgumentNullException("columnRef");
            }

            if (!Regex.IsMatch(columnRef, @"^[A-Z]+$"))
            {
                throw new FormatException("Column reference not valid");
            }

            return ColToIntRec(columnRef);
        }