1 Reply Latest reply on Mar 24, 2009 5:58 PM by 513533

    Getting incomplete end of file when using fetchCalendarEventsByRange

      When using fetchEventsByRange() to fetch calendar, I am getting incomplete end of file. Some
      user's ics files end with "END:VCA", some with "END:VACLANE", some with
      just "END:VEVENT". Does anyone have similar experience? Thanks.

      The code I am using to export ics file is:

      private String fetchCalendarEventsByRange(String startDate, String endDate) {

      String properties[] = new String[0];
      RequestResult results = new RequestResult();
      String iCalendar = new String();

      try {
      iCalendar = mySession.fetchEventsByRange(Api.CSDK_FLAG_STREAM_NOT_MIME | Api.CSDK_FLAG_FETCH_EXCLUDE_HOLIDAYS,
      agendas, // search agenda of current user
      properties, // request specific properties

      return iCalendar;
      catch(Api.StatusException e) {
      System.err.println("fetchEventsByRange returned status'" + e + "'");
      return null;
        • 1. Re: Getting incomplete end of file when using fetchCalendarEventsByRange

          The code snippet provided with this question was used in the lab in an attempt to reproduce the problem; behavior did not occur. Also to note: several (3rd party) applications have used this function for years with no reports of such behavior (as far as the R&D team is aware.)

          This may be specific to a particular environment. Suggestion: try the code on a completely separate setup (i.e. avoid cloned installations or hosts that are configured from a similar template.) Does the behavior change?