oRange = oSheet.getCellRangeByName("C1:D4");
oRanges.insertByName("Range1", oRange);
oRange = oSheet.getCellRangeByName("E2:F5");
oRanges.insertByName("Range2", oRange);
oRange = oSheet.getCellRangeByName("G2:H3");
oRanges.insertByName("Range3", oRange);
oRange = oSheet.getCellRangeByName("I7:J8");
oRanges.insertByName("Range4", oRange);
} catch(com.sun.star.lang.WrappedTargetException e) {
e.printStackTrace(log);
throw new StatusException("Couldn't create test object", e);