Package ag.ion.bion.officelayer.text

Examples of ag.ion.bion.officelayer.text.TextException


    try {
      XCell xCell = xTextTable.getCellByName(name);
      if (xCell != null)
        return new TextTableCell(textDocument, xCell);
      else
        throw new TextException("A column with the name " + name
            + " is not available.");
    } catch (Exception exception) {
      TextException textException = new TextException(exception
          .getMessage());
      textException.initCause(exception);
      throw textException;
    }
  }
View Full Code Here


          cellRangeName);
      TextTableCellRange textTableCellRange = new TextTableCellRange(
          textDocument, newXCellRange, textTableCellRangeName);
      return textTableCellRange;
    } catch (Exception exception) {
      TextException textException = new TextException(exception
          .getMessage());
      textException.initCause(exception);
      throw textException;
    }
  }
View Full Code Here

   */
  public void removeRow(int index) throws TextException {
    try {
      xTextTable.getRows().removeByIndex(index, 1);
    } catch (Exception exception) {
      TextException textException = new TextException(
          "The specified row could not be removed");
      textException.initCause(exception);
    }
  }
View Full Code Here

   */
  public void removeRows(int index, int count) throws TextException {
    try {
      xTextTable.getRows().removeByIndex(index, count);
    } catch (Exception exception) {
      TextException textException = new TextException(
          "The specified row could not be removed");
      textException.initCause(exception);
    }
  }
View Full Code Here

  public void remove() throws TextException {
    try {
      textDocument.getTextService().getTextContentService()
          .removeTextContent(this);
    } catch (Exception exception) {
      TextException textException = new TextException(
          "The specified table can not be removed");
      textException.initCause(exception);
    }
  }
View Full Code Here

      else {
        return false;
      }
    }
    else {
      throw new TextException("Problems getting font italic");
    }
  }
View Full Code Here

   * @author Andreas Br�ker
   */
  public ITextTable constructTextTable(int rows, int columns)
      throws TextException {
    if (columns > ITextTable.MAX_COLUMNS_IN_TABLE) {
      throw new TextException("The submitted table is not valid");
    }
    try {
      XMultiServiceFactory xMultiServiceFactory = (XMultiServiceFactory) UnoRuntime
          .queryInterface(XMultiServiceFactory.class, textDocument
              .getXTextDocument());
      Object newTable = xMultiServiceFactory
          .createInstance("com.sun.star.text.TextTable");
      XTextTable newTextTable = (XTextTable) UnoRuntime.queryInterface(
          XTextTable.class, newTable);
      newTextTable.initialize(rows, columns);

      TextTable textTable = new TextTable(textDocument, newTextTable);
      return textTable;
    } catch (Exception exception) {
      TextException textException = new TextException(exception
          .getMessage());
      textException.initCause(exception);
      throw textException;
    }
  }
View Full Code Here

      Any any = (Any) xNameAccess.getByName(name);
      XTextTable textTable = (XTextTable) any.getObject();
      if (textTable.getColumns().getCount() <= ITextTable.MAX_COLUMNS_IN_TABLE) {
        return new TextTable(textDocument, textTable);
      } else {
        throw new TextException("The submitted table is not valid");
      }
    } catch (Exception exception) {
      TextException textException = new TextException(exception
          .getMessage());
      textException.initCause(exception);
      throw textException;
    }
  }
View Full Code Here

  public void setContent(String content) throws TextException {
    try {
      xPropertySet.setPropertyValue("Content", content);
    }
    catch(Exception exception) {
      throw new TextException(exception);
    }   
  }
View Full Code Here

        textFields[i] = new TextField(textDocument, dependentTextFields[i]);
      }
      return textFields;
    }
    catch(Exception exception) {
      throw new TextException(exception);
    }
  }
View Full Code Here

TOP

Related Classes of ag.ion.bion.officelayer.text.TextException

Copyright © 2018 www.massapicom. 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.