Gets or sets the unique identifier of the resource associated with the current appointment, or the ID of the first resource if resource sharing is enabled.
A Object value that specifies the resource’s unique identifier.
The ResourceId property specifies the identifier of the appointment’s associated resource. All resources must have unique IDs.
Use the Appointment.ResourceIds property to get a collection of associated resources if resource sharing is enabled.
Resources are used to group schedules. An appointment can be associated with a resource, or it can be standalone. To associate an appointment with a resource, the appointment’s ResourceId property should be set to the value specified by the required resource’s IPersistentObject.Id property. For standalone appointments, the ResourceId property is set to the EmptyResourceId value.
If resource sharing is enabled (the AppointmentStorageBase.ResourceSharing property is set to true), the ResourceId property returns the ID of the first resource contained in the Appointment.ResourceIds collection.
If an appointment doesn’t belong to any particular resource (the ResourceId property is set to the EmptyResourceId), the scheduler shows it for all resources when the SchedulerControl.GroupType property is set to the SchedulerGroupType.Resource or SchedulerGroupType.Date value. . Appointments without assigned resources are hidden if the SchedulerOptionsViewBase.ShowOnlyResourceAppointments property is set to true.
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the ResourceId property.
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.