Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

The Durationproperty gets or sets the length of a recurring Appointment, in minutes (not the length of time that the recurrence pattern lasts).

To get the value of the Durationproperty, call the property method described here.

To set the value of the Durationproperty, see the IRecurrencePattern::put_Durationproperty method.

Syntax

HRESULT get_Duration(
  long * 
plDuration
);

Parameters

plDuration

[out] Reference to an integer value indicating the length of time, in minutes, of the recurring Appointment.

Return Value

This method returns the standard values E_INVALIDARG, E_OUTOFMEMORY, E_UNEXPECTED, and E_FAIL, as well as the following:

S_OK

The method completed successfully.

Remarks

Recurrence duration applies to IAppointmentitems only.

Recurrence duration is the difference between PIMPR_RECURRING_ENDTIMEand PIMPR_RECURRING_STARTTIME.

If you do not set the duration, Outlook Mobile sets it from information contained in the Appointment item.

The Durationvalue is ignored if you set both IRecurrencePattern::put_StartTimeand IRecurrencePattern::put_EndTime. If you set only one, Outlook Mobile uses the Durationvalue to calculate the other.

The Durationvalue cannot be longer than 31 days.

When you change a Recurrence Pattern's Durationproperty, the Duration property of each Appointment item that is associated with this Recurrence Pattern also changes. For example, you might use IRecurrencePattern::put_Durationif you wanted to change the duration of a weekly meeting from 60 minutes, to 30 minutes.

The Startand Endtimes for recurring Appointments are set in terms of the Timezone property ( PIMPR_TIMEZONE), but the Startand Endtimes for individual Appointments are set and read in terms of the local (Windows Mobile device's) Timezone. For example, a recurring Appointment set to recur at noon London time, would occur at 4:00 AM Pacific time.

Requirements

Header pimstore.h
Library Pimstore.lib
Windows Embedded CE Windows CE 2.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also