vcl-cxcustomdata-dot-tcxcustomdatacontroller-1f8ee552.md
Returns a pattern data controller for a detail data controller.
function GetPatternDataController: TcxCustomDataController;
| Type |
|---|
| TcxCustomDataController |
The GetPatternDataController function can be applied only to detail data controllers. Data controllers, which are not details, have no patterns at all.
The function returns a pattern data controller for the current detail data controller.
A pattern data controller does not contain data and is only used to provide settings when creating its clones (instances of the detail data controller corresponding to specific records in a master data controller). Refer to the TcxCustomDataController description for more information on patterns and clones. To know whether the current data controller is a pattern or a non-pattern, use the IsPattern property.
If the current data controller is a pattern, GetPatternDataController returns a reference to the current object.
Changing settings of a pattern data controller does not affect its existing clones. However, you can call the ClearDetails method of a master data controller to recreate detail clones based on the settings of the pattern detail data controller.
To return a master data controller, use the GetMasterDataController function.
See Also
TcxCustomDataController.ClearDetails
TcxCustomDataController.CollapseDetails
TcxCustomDataController.GetDetailDataController
TcxCustomDataController.GetMasterDataController
TcxCustomDataController.GetMasterRecordIndex
TcxCustomDataController.IsDetailMode
TcxCustomDataController.IsPattern