Examples of XCellRangeAddressable


Examples of com.sun.star.sheet.XCellRangeAddressable

            log.println("getReferredCells returned NULL.");
            tRes.tested("getReferredCells()", false);
            return;
        }

        XCellRangeAddressable xCRA = (XCellRangeAddressable)
                UnoRuntime.queryInterface(XCellRangeAddressable.class, cr);

        CellRangeAddress objCRA = xCRA.getRangeAddress();

        log.println("The named range was 'ANamedRange A1:B2'");
        log.println("Expected CellRangeAddress: (" + oldCRA.Sheet +
            "," + oldCRA.StartColumn + "," + oldCRA.StartRow + "," +
            oldCRA.EndColumn + "," + objCRA.EndRow + ")");
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

    }
   
    // method returns false if the ranges are equal and true otherwise
   
    private boolean compareRanges(Object old, Object newEl) {
        XCellRangeAddressable xCRA = (XCellRangeAddressable)
                UnoRuntime.queryInterface(XCellRangeAddressable.class,old);
       
        XCellRangeAddressable xCRA2 = (XCellRangeAddressable)
                UnoRuntime.queryInterface(XCellRangeAddressable.class,newEl);
               
        int orgStartCol = xCRA.getRangeAddress().StartColumn;
        int orgEndCol = xCRA.getRangeAddress().EndColumn;       
        int orgStartRow = xCRA.getRangeAddress().StartRow;
        int orgEndRow = xCRA.getRangeAddress().EndRow;               
       
        int newStartCol = xCRA2.getRangeAddress().StartColumn;
        int newEndCol = xCRA2.getRangeAddress().EndColumn;       
        int newStartRow = xCRA2.getRangeAddress().StartRow;
        int newEndRow = xCRA2.getRangeAddress().EndRow;
       
        boolean ret = true;
       
        if (orgStartCol == newStartCol) {
            log.println("\t StartColumn is the same");
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

        Rectangle oRect = new Rectangle(500, 3000, 25000, 11000);

        XCellRange oRange = (XCellRange)
            UnoRuntime.queryInterface(XCellRange.class, oSheet);
        XCellRange myRange = oRange.getCellRangeByName("A1:N4");
        XCellRangeAddressable oRangeAddr = (XCellRangeAddressable)
            UnoRuntime.queryInterface(XCellRangeAddressable.class, myRange);
        CellRangeAddress myAddr = oRangeAddr.getRangeAddress();

        CellRangeAddress[] oAddr = new CellRangeAddress[1];
        oAddr[0] = myAddr;
        XTableChartsSupplier oSupp = (XTableChartsSupplier)
            UnoRuntime.queryInterface(XTableChartsSupplier.class, oSheet);
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

        XScenariosSupplier xSupp = (XScenariosSupplier)
            UnoRuntime.queryInterface(XScenariosSupplier.class, oSheet);
        XCellRange oRange = (XCellRange)
            UnoRuntime.queryInterface(XCellRange.class, oSheet);
        XCellRange myRange = oRange.getCellRangeByName("A1:N4");
        XCellRangeAddressable oRangeAddr = (XCellRangeAddressable)
            UnoRuntime.queryInterface(XCellRangeAddressable.class, myRange);
        CellRangeAddress myAddr = oRangeAddr.getRangeAddress();

        CellRangeAddress[] oAddr = new CellRangeAddress[1];
        oAddr[0] = myAddr;

        xSupp.getScenarios().addNewByName("ScScenarios", oAddr, "Range");
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

        XScenariosSupplier xSupp = (XScenariosSupplier)
            UnoRuntime.queryInterface(XScenariosSupplier.class, oSheet);
        XCellRange oRange = (XCellRange)
            UnoRuntime.queryInterface(XCellRange.class, oSheet);
        XCellRange myRange = oRange.getCellRangeByName("A1:N4");
        XCellRangeAddressable oRangeAddr = (XCellRangeAddressable)
            UnoRuntime.queryInterface(XCellRangeAddressable.class, myRange);
        CellRangeAddress myAddr = oRangeAddr.getRangeAddress();

        CellRangeAddress[] oAddr = new CellRangeAddress[1];
        oAddr[0] = myAddr;

        xSupp.getScenarios().addNewByName("ScScenarios", oAddr, "Range");
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

        Object[] selections = {oSheet, cellRange, cell_1, cell_2};
        tEnv.addObjRelation("Selections", selections);
       
        tEnv.addObjRelation("Comparer", new Comparator() {
            public int compare(Object o1, Object o2) {
                XCellRangeAddressable adr1 = (XCellRangeAddressable)
                UnoRuntime.queryInterface(XCellRangeAddressable.class, o1);
                XCellRangeAddressable adr2 = (XCellRangeAddressable)
                UnoRuntime.queryInterface(XCellRangeAddressable.class, o2);
                if (adr1 == null || adr2 == null) return -1;
                CellRangeAddress range1 = adr1.getRangeAddress();
                CellRangeAddress range2 = adr2.getRangeAddress();
                return ValueComparer.equalValue(range1, range2) ? 0 : 1 ;
            }
            public boolean equals(Object obj) {
                return compare(this, obj) == 0;
            } });
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

    public void _gotoNext(){
        boolean bResult = false;
        int startCol, endCol, startRow, endRow = 0;
        int startCol2, endCol2, startRow2, endRow2 = 0;

        XCellRangeAddressable oRange = (XCellRangeAddressable)
            UnoRuntime.queryInterface(XCellRangeAddressable.class, oObj);
        CellRangeAddress oAddr = oRange.getRangeAddress();
        startRow = oAddr.StartRow;
        startCol = oAddr.StartColumn;
        endRow = oAddr.EndRow;
        endCol = oAddr.EndColumn;

        oObj.gotoNext();

        oAddr = oRange.getRangeAddress();
        startRow2 = oAddr.StartRow;
        startCol2 = oAddr.StartColumn;
        endRow2 = oAddr.EndRow;
        endCol2 = oAddr.EndColumn;
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

    public void _gotoOffset(){
        boolean bResult = false;
        int startCol, endCol, startRow, endRow = 0;
        int startCol2, endCol2, startRow2, endRow2 = 0;

        XCellRangeAddressable oRange = (XCellRangeAddressable)
            UnoRuntime.queryInterface(XCellRangeAddressable.class, oObj);
        CellRangeAddress oAddr = oRange.getRangeAddress();
        startRow = oAddr.StartRow;
        startCol = oAddr.StartColumn;
        endRow = oAddr.EndRow;
        endCol = oAddr.EndColumn;

        oObj.gotoOffset(4,4);

        oAddr = oRange.getRangeAddress();
        startRow2 = oAddr.StartRow;
        startCol2 = oAddr.StartColumn;
        endRow2 = oAddr.EndRow;
        endCol2 = oAddr.EndColumn;
        if (!(startCol == startCol2) || (startRow == startRow2)){
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

    public void _gotoPrevious(){
        boolean bResult = false;
        int startCol, endCol, startRow, endRow = 0;
        int startCol2, endCol2, startRow2, endRow2 = 0;

        XCellRangeAddressable oRange = (XCellRangeAddressable)
                  UnoRuntime.queryInterface(XCellRangeAddressable.class, oObj);
        CellRangeAddress oAddr = oRange.getRangeAddress();
        startRow = oAddr.StartRow;
        startCol = oAddr.StartColumn;
        endRow = oAddr.EndRow;
        endCol = oAddr.EndColumn;

        oObj.gotoPrevious();

        oAddr = oRange.getRangeAddress();
        startRow2 = oAddr.StartRow;
        startCol2 = oAddr.StartColumn;
        endRow2 = oAddr.EndRow;
        endCol2 = oAddr.EndColumn;
View Full Code Here

Examples of com.sun.star.sheet.XCellRangeAddressable

     */
    public void _gotoStart(){
        boolean bResult = false;
        int startCol, endCol, startRow, endRow = 0;

        XCellRangeAddressable oRange = (XCellRangeAddressable)
                UnoRuntime.queryInterface(XCellRangeAddressable.class, oObj);
        oObj.gotoStart();
        CellRangeAddress oAddr = oRange.getRangeAddress();
        startRow = oAddr.StartRow;
        startCol = oAddr.StartColumn;
        endRow = oAddr.EndRow;
        endCol = oAddr.EndColumn;
        if ((startCol == endCol) && (endRow == startRow)){
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.