// do not execute com::sun::star::sheets::XCellSeries::fillAuto()
tEnv.addObjRelation("XCELLSERIES_FILLAUTO", new Boolean(false));
// set the adress ranges of the cells (see values set above): for e.g. XSheetOutline test
tEnv.addObjRelation("CellRangeAddress",
new CellRangeAddress((short)0, 6, 6, 8, 8));
tEnv.addObjRelation("CellRangeSubAddress",
new CellRangeAddress((short)0, 6, 6, 7, 8));
// pick a cell with a formula for XSheetAuditing, a dependent cell and a precedent cell
tEnv.addObjRelation("XSheetAuditing.CellAddress", new CellAddress((short)0, 8, 6));
tEnv.addObjRelation("XSheetAuditing.PrecedentCellAddress", new CellAddress((short)0, 7, 6));
tEnv.addObjRelation("XSheetAuditing.DependentCellAddress", new CellAddress((short)0, 9, 6));
// add an existing sheet for linking
tEnv.addObjRelation("XSheetLinkable.LinkSheet", "ScSheetLinksObj.sdc");
//adding Scenario and with that a ScenarioSheet-Relation for Scenario and XScenarioEnhanced
XScenariosSupplier scene = (XScenariosSupplier) UnoRuntime.queryInterface(
XScenariosSupplier.class,
tEnv.getTestObject());
scene.getScenarios()
.addNewByName("Scenario",
new CellRangeAddress[] {
new CellRangeAddress((short) 0, 0, 0, 10, 10)
}, "Comment");
XSpreadsheet sSheet = null;
try {