DataViewExtensionBase.BindToLINQ(Type, String, EventHandler<LinqServerModeDataSourceSelectEventArgs>) Method

Binds the DataView to a queryable source.

Namespace: DevExpress.Web.Mvc

Assembly: DevExpress.Web.Mvc5.v21.1.dll

Declaration

public DataViewExtensionBase BindToLINQ(
    Type contextType,
    string tableName,
    EventHandler<LinqServerModeDataSourceSelectEventArgs> selectingMethod
)

Parameters

Name Type Description
contextType Type

A Type specifying the DataContext type.

tableName String

A String object specifying the table name.

selectingMethod EventHandler<LinqServerModeDataSourceSelectEventArgs>

Returns

Type Description
DataViewExtensionBase

A DataViewExtensionBase object representing the DataView extension.

Remarks

Note

The current BindToLINQ overload catches and conceals any exception thrown by an IQueryable provider. To catch these exceptions manually, use the BindToLINQ(string contextTypeName, string tableName, EventHandler<LinqServerModeDataSourceSelectEventArgs> selectingMethod, EventHandler<ServerModeExceptionThrownEventArgs> exceptionThrownMethod) overload method.

See Also