public static int convertColToInt ( final String col ) { String name = col . toUpperCase ( ) ; int number = 0 ; int pow = 1 ; for ( int i = name . length ( ) - 1 ; i >= 0 ; i -- ) { number += ( name . charAt ( i ) - ' ' + 1 ) * pow ; pow *= TieConstants . EXCEL_LETTER_NUMBERS ; } return number - 1 ; }
Convert col to int .