Calling XSSFSheet.setAutofilter(CellRangeAddress.valueOf("A:D")) does not throw any exception and applies the autofilter on sheet for these columns but Calling HSSFSheet.setAutofilter(CellRangeAddress.valueOf("A:D")) THROWS THIS EXCEPTION : "row1 must be between 0 and 65280" Why this inconsistent behavior?
Fix in r1554688, HSSF now also accepts column-only-ranges, also the XSSF side was fixed to allow to change the autofilter via a second call to setAutoFilter().