Package jp.ne.so_net.ga2.no_ji.jcom

Examples of jp.ne.so_net.ga2.no_ji.jcom.IDispatch


     * @param dataset DataSet
     * @param name Indice-Name
     */
    public void sort(IDispatch dataset, String name) {
        try {
            IDispatch tosort = (IDispatch) dataset.get("Indices", new Object[]{name});
            tosort.method("Select", null);
        } catch (JComException ex) {
            ErrorHandling.showError("Indices " + name + " nicht vorhanden.");
        }
    }
View Full Code Here


     * @param endvalue Ende
     */
    public void setRange(IDispatch dataset, String art, String startvalue, String endvalue) {
        try {
            dataset.method("editrangestart", null);
            IDispatch fields = (IDispatch) dataset.get("Fields", new Object[]{art});
            fields.put("AsString", startvalue);
            dataset.method("editrangeend", null);
            fields = (IDispatch) dataset.get("Fields", new Object[]{art});
            fields.put("AsString", endvalue);
            dataset.method("applyrange", null);
        } catch (JComException ex) {
            ErrorHandling.showError("SetRange nicht möglich.");
        }
    }
View Full Code Here

  // performs 100 calls in 5 seconds
  private boolean writeEvent(String subject, String body, Date start, Date end, int reminderMinutesBeforeStart,
      boolean reminderSet, int busyStatus, String categories, boolean durationIs0, int sensitivity) {

    ReleaseManager rm = null;
    IDispatch outlook;
    IDispatch item;
    try {
      System.loadLibrary("JCom");
      rm = new ReleaseManager();
      try {
        outlook = new IDispatch(rm, "Outlook.Application");
      } catch (jp.ne.so_net.ga2.no_ji.jcom.JComException ex) {
        JOptionPane.showMessageDialog(CalendarExportPlugin.getInstance().getBestParentFrame(), mLocalizer.msg(
            "noOutlookFound", "MS Outlook is not installed."), Localizer.getLocalization(Localizer.I18N_ERROR),
            JOptionPane.WARNING_MESSAGE);
        return false;
      }
      item = (IDispatch) outlook.invoke("CreateItem", IDispatch.PROPERTYGET, new Integer[] { olAppointmentItem });
      item.put("Subject", subject);
      item.put("Body", body);
      item.put("Start", correctTimeZone(start));
      item.put("End", correctTimeZone(end));
      item.put("ReminderSet", reminderSet);
      if (reminderSet) {
        item.put("ReminderMinutesBeforeStart", reminderMinutesBeforeStart);
      }
      item.put("BusyStatus", busyStatus);
      item.put("Categories", categories);
      if (durationIs0) {
        item.put("Duration", 0);
      }
      item.put("Sensitivity", sensitivity);
      item.method("Save", null);
      item.release();
      outlook.release();
    } catch (Exception e) {
      e.printStackTrace();
      ErrorHandler.handle(mLocalizer
          .msg("exportError", "An error occured while creating an appointment in MS Outlook."), e);
      return false;
    } finally {
      if (rm != null) {
        rm.release();
      }
    }
    return true;
  }
View Full Code Here

    /**
     * Konstruktor.
     */
    public BPN() {
        rm = new ReleaseManager();
        try {
            try {
                try {
                    app = new IDispatch(rm, "BpNT.Application");
                    appusable = true;
View Full Code Here

TOP

Related Classes of jp.ne.so_net.ga2.no_ji.jcom.IDispatch

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.