public static Cell getCellByReference ( final String cellRef , final Sheet sheet ) { Cell c = null ; try { CellReference ref = new CellReference ( cellRef ) ; Row r = sheet . getRow ( ref . getRow ( ) ) ; if ( r != null ) { c = r . getCell ( ref . getCol ( ) , MissingCellPolicy . CREATE_NULL_AS_BLANK ) ; } } catch ( Exception ex ) { // use log.debug because mostly it's expected LOG . log ( Level . SEVERE , "WebForm WebFormHelper getCellByReference cellRef = " + cellRef + "; error = " + ex . getLocalizedMessage ( ) , ex ) ; } return c ; }
Gets the cell by reference .