XPObjectSpace.FindObject(Type, CriteriaOperator, Boolean) Method

Searches for the first object which matches the specified criteria.

Namespace: DevExpress.ExpressApp.Xpo

Assembly: DevExpress.ExpressApp.Xpo.v18.1.dll

Declaration

public override object FindObject(
    Type objectType,
    CriteriaOperator criteria,
    bool inTransaction
)
Public Overrides Function FindObject(
    objectType As Type,
    criteria As CriteriaOperator,
    inTransaction As Boolean
) As Object

Parameters

Type Name Description
Type objectType

A Type object which is the type of objects to search for.

CriteriaOperator criteria

A DevExpress.Data.Filtering.CriteriaOperator descendant which is the criteria for matching persistent objects.

Boolean inTransaction

true if all objects (in the database and retrieved) are processed by the specified criteria; otherwise, false.

Returns

Type Description
Object

An object which is the first persistent object which matches the specified criteria. null (Nothing in Visual Basic) if there is no persistent object which matches the criteria.

This method searches for an object, both if the specified object type is a class and if the specified object type is an interface.

Persistent objects that are marked for deletion are not included in the search.

See Also