ECal.recur_ensure_end_dates
Description: Reference for ECal.recur_ensure_end_dates

### Function

# ECalrecur_ensure_end_dates

since: 2.32

#### Declaration [src]

    gboolean
    e_cal_recur_ensure_end_dates (
      ECalComponent* comp,
      gboolean refresh,
      ECalRecurResolveTimezoneCb tz_cb,
      gpointer tz_cb_data,
      GCancellable* cancellable,
      GError** error
    )

#### Description [src]

This recalculates the end dates for recurrence & exception rules which use the COUNT property. If `refresh` is `TRUE` it will recalculate all enddates for rules which use COUNT. If `refresh` is `FALSE`, it will only calculate the enddate if it hasn’t already been set. It returns `TRUE` if the component was changed, i.e. if the component should be saved at some point. We store the enddate in the `E_CAL_EVOLUTION_ENDDATE_PARAMETER` parameter of the RRULE or EXRULE.

Available since: 2.32

#### Parameters

`comp`

  Type: `ECalComponent`

  An `ECalComponent`.

  The data is owned by the caller of the function.

`refresh`

  Type: `gboolean`

  `TRUE` to recalculate all end dates.

`tz_cb`

  Type: `ECalRecurResolveTimezoneCb`

  Function to call to resolve timezones.

`tz_cb_data`

  Type: `gpointer`

  User data to pass to `tz_cb`.

  The argument can be `NULL`.
  The data is owned by the caller of the function.

`cancellable`

  Type: `GCancellable`

  Optional `GCancellable` object, or `NULL`.

  The argument can be `NULL`.
  The data is owned by the caller of the function.

`error`

  Type: `GError **`

  The return location for a recoverable error.

  The argument can be `NULL`.
  If the return location is not `NULL`, then you must initialize it to a `NULL` `GError*`.
  The argument will be left initialized to `NULL` by the function if there are no errors.
  In case of error, the argument will be set to a newly allocated `GError`; the caller will take ownership of the data, and be responsible for freeing it.

#### Return value

Type: `gboolean`

`TRUE` if the component was changed, `FALSE` otherwise.