2022 Class
Changes 6
C

ScheduleDefinition

Description:
Settings that define the contents of a schedule.
Remarks:

The ScheduleDefinition class contains various settings that define the contents of a schedule view, including:

  • The schedule's category and other basic properties that determine the type of schedule.
  • A set of fields that become the columns of the schedule.
  • Filters that restrict the set of elements visible in the schedule.
  • Sorting and grouping criteria.

Most schedules contain a single ScheduleDefinition. In Revit MEP, schedules of certain categories can contain an "embedded schedule" containing elements associated with the elements in the primary schedule, for example a room schedule showing the elements inside each room or a duct system schedule showing the elements associated with each system. An embedded schedule has its own category, fields, filters, etc. Those settings are stored in a second ScheduleDefinition object.

Inheritance Hierarchy:
System.Object
  Autodesk.Revit.DB.ScheduleDefinition
public class ScheduleDefinition : IDisposable
Name Return Type Description
M AddEmbeddedSchedule(ElementId) None Adds an embedded ScheduleDefinition.
M AddField(SchedulableField) The new field. Adds a regular field at the end of the list.
M AddField(ScheduleFieldType) The new field. Adds a regular field at the end of the list.
M AddField(ScheduleFieldType, ElementId) The new field. Adds a regular field at the end of the list.
M AddFilter(ScheduleFilter) None Adds a new filter at the end of the list.
M AddSortGroupField(ScheduleSortGroupField) None Adds a new sorting/grouping field at the end of the list.
M CanFilterByGlobalParameters(ScheduleFieldId) bool Checks whether a field can be used with a global parameter-based filter.
M CanFilterByParameterExistence(ScheduleFieldId) bool Checks whether a field can be used with a HasParameter filter.
M CanFilterBySubstring(ScheduleFieldId) bool Checks whether a field can be used with a substring-based filter.
M CanFilterByValue(ScheduleFieldId) bool Checks whether a field can be used with a value-based filter.
M CanFilterByValuePresence(ScheduleFieldId) bool Checks whether a field can be used with a value presence-based filter.
M CanFilter() bool Checks whether filters can be added to this ScheduleDefinition.
M CanHaveEmbeddedSchedule() bool Indicates if this ScheduleDefinition can have an embedded ScheduleDefinition added.
M CanIncludeLinkedFiles() bool Checks whether the schedule is a type that supports including elements from linked files.
M CanSortByField(ScheduleFieldId) bool Checks whether a field can be used for sorting/grouping.
M ClearFields() None Removes all fields.
M ClearFilters() None Removes all filters.
M ClearSortGroupFields() None Removes all sorting/grouping fields.
M Dispose() None Releases all resources used by the
M GetFieldCount() int Gets the number of fields in this ScheduleDefinition.
M GetFieldId(Int32) The field ID. Converts a field index to the corresponding field ID.
M GetFieldIndex(ScheduleFieldId) The field index. Converts a field ID to the corresponding field index.
M GetField(Int32) The field. Gets a field.
M GetField(ScheduleFieldId) The field. Gets a field.
M GetFieldOrder() IList<ScheduleFieldId> Gets the IDs of the current list of fields in order.
M GetFilterCount() int Gets the number of filters in this ScheduleDefinition.
M GetFilter(Int32) ScheduleFilter Gets a filter.
M GetFilters() IList<ScheduleFilter> Gets all filters in this ScheduleDefinition.
M GetSchedulableFields() IList<SchedulableField> Gets a list of all non-calculated/non-combined fields that are eligible to be included in this schedule.
M GetSortGroupFieldCount() int Gets the number of sorting/grouping fields in this ScheduleDefinition.
M GetSortGroupField(Int32) ScheduleSortGroupField Gets a sorting/grouping field.
M GetSortGroupFields() IList<ScheduleSortGroupField> Gets all sorting/grouping fields in this ScheduleDefinition.
M GetValidCategoriesForEmbeddedSchedule() ICollection<ElementId> Get all categories that can be used for an embedded ScheduleDefinition in this ScheduleDefinition.
M InsertCombinedParameterField(IList<TableCellCombinedParameterData>, String, Int32) The new field. Adds a combined parameter field at the specified position in the list.
M InsertField(SchedulableField, Int32) The new field. Adds a regular field at the specified position in the list.
M InsertField(ScheduleFieldType, ElementId, Int32) The new field. Adds a regular field at the specified position in the list.
M InsertField(ScheduleFieldType, Int32) The new field. Adds a regular field at the specified position in the list.
M InsertFilter(ScheduleFilter, Int32) None Adds a new filter at the specified position in the list.
M InsertSortGroupField(ScheduleSortGroupField, Int32) None Adds a new sorting/grouping field at the specified position in the list.
M IsSchedulableField(SchedulableField) bool Checks whether a non-calculated/non-combined field is eligible to be included in this schedule.
M IsValidCategoryForEmbeddedSchedule(ElementId) bool Indicates if a category can be used for an embedded ScheduleDefinition in this ScheduleDefinition.
M IsValidCombinedParameters(IList<TableCellCombinedParameterData>) bool Checks if data is valid for combined parameters
M IsValidFieldId(ScheduleFieldId) bool Checks whether a ScheduleFieldId is the ID of a field in this ScheduleDefinition.
M IsValidFieldIndex(Int32) bool Checks whether an integer is a valid zero-based field index in this ScheduleDefinition.
M RemoveEmbeddedSchedule() None Removes the embedded ScheduleDefinition.
M RemoveField(Int32) None Removes a field.
M RemoveField(ScheduleFieldId) None Removes a field.
M RemoveFilter(Int32) None Removes a filter.
M RemoveSortGroupField(Int32) None Removes a sorting/grouping field.
M SetFieldOrder(IList<ScheduleFieldId>) None Reorders the fields in the schedule.
M SetFilter(Int32, ScheduleFilter) None Replaces a filter.
M SetFilters(IList<ScheduleFilter>) None Replaces all filters in this ScheduleDefinition.
M SetSortGroupField(Int32, ScheduleSortGroupField) None Replaces a sorting/grouping field.
M SetSortGroupFields(IList<ScheduleSortGroupField>) None Replaces all sorting/grouping fields in this ScheduleDefinition.
Name Return Type Description
P AreaSchemeId ElementId In an area schedule, the ID of the area scheme to display.
P CategoryId ElementId The category ID of elements appearing in the schedule.
P EmbeddedDefinition ScheduleDefinition The embedded ScheduleDefinition.
P FamilyId ElementId In a note block schedule, the ID of the Generic Annotation family displayed by the schedule.
P GrandTotalTitle string The title name is used to display at the grand total row. The name is "Grand total", expressed in the Revit session language, by default.
P HasEmbeddedSchedule bool Indicates if this ScheduleDefinition has an embedded ScheduleDefinition.
P IncludeLinkedFiles bool Indicates if the schedule includes elements from linked files.
P IsEmbedded bool Indicates if this is an embedded ScheduleDefinition.
P IsItemized bool Indicates if the schedule displays each element on a separate row or combines multiple grouped elements onto the same row.
P IsKeySchedule bool Indicates if the schedule is a key schedule.
P IsMaterialTakeoff bool Indicates if the schedule is a material takeoff.
P IsValidObject bool Specifies whether the .NET object represents a valid Revit entity.
P ShowGrandTotalCount bool Indicates if the grand total row should display a count of elements in the schedule.
P ShowGrandTotal bool Indicates if a grand total row should be displayed at the bottom of the schedule.
P ShowGrandTotalTitle bool Indicates if the grand total row should display a title.
P ShowGridLines bool Indicates if the schedule grid lines will be visible on a sheet.
P ShowHeaders bool Indicates if the headers will be displayed in the schedule.
P ShowTitle bool Indicates if the title will be displayed in the schedule.