ObjectDataSource.BeforeFill Event
Occurs before filling an object data source, which enables you to provide custom data source validation.
Namespace: DevExpress.DataAccess.ObjectBinding
Assembly: DevExpress.DataAccess.v24.2.dll
NuGet Package: DevExpress.DataAccess
#Declaration
public event BeforeFillEventHandler BeforeFill
#Event Data
The BeforeFill event's data class is BeforeFillEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
Constructor |
Returns an object providing access to constructor parameters of an Object |
Data |
Returns the data member specified for an Object |
Data |
Returns the data source assigned to an Object |
Is |
Specifies whether or not the object data source is valid. |
Parameters |
Returns a collection of method and constructor parameters of an Object |
#Remarks
The BeforeFill event occurs before filling an object data source.
If the BeforeFillEventArgs.IsValid property returns false, a ValidationFailedException is thrown.
Important
Before
is false
if the object data source uses an untrusted data source type.
To validate all object data sources in an entire application, handle the ObjectDataSource.BeforeFillGlobal event.