This sample shows how to retrieve valid state transitions regardless of whether custom state transitions have been defined for the table.
See How to run samples for information about how to run this sample.
The GetValidStatusOptions
method is intended to be used in a scenario where it contains data that returns valid status option transitions regardless of whether state transitions are enabled for the table.
In order to simulate the scenario described in What this sample does, the sample will do the following:
- Checks for the current version of the org.
- The
MetadataFilterExpression
method checks for table definitions.
- The
MetadataFilterExpression
method retrieves the status options for theIncident
table. - The
RetrieveMetadataChangeRequest
method retrieves table definitions. - The
GetValidStatusOptions
method gets the valid status transitions for each status option.
This sample creates no records. No clean up is required.