Description:
The GetList method retrieves a list of available
calendars or calendar entries. Calendar entries are retrieved from the specified
calendar or, if no calendar is specified, from the default one.
This is a synchronous method.
Syntax:
GetList(parameters:Object):Object
Arguments:
parameters:
This is an object that specifies what calendar information is returned. For more information about the object properties and how to define them, see section Parameters for retrieving calendar information.
Return value:
The GetList method returns an object that contains
the requested calendar information, an error code, and an error message.
|
Property |
Description |
Value |
|---|---|---|
|
|
This is an iterator that contains the requested calendar information. |
|
|
|
This is a number that specifies a predefined error code. |
|
|
|
This is a text string that describes the error. |
Remarks:
If entries are retrieved from a calendar other than the default one, the corresponding calendar file must exist on the device.
For detailed information about calendar entries, see section Calendar entries.
Example code:
The following sample code illustrates how to retrieve a calendar:
import com.nokia.lib.Service;
var calender = new Service("Service.Calendar", "IDataSource");
var inParams = {Type:"CalendarEntry"};
var outParams = calender.GetList(inParams);
var outList = outParams.ReturnValue;
var outputEntry = null;
do {
outputEntry = outList.next();
if (null != outputEntry) {
var id = outputEntry.id;
} else {
break;
}
} while (true);