ObjectDataSource.DataMember Property

Specifies the data member of an object data source.

Namespace: DevExpress.DataAccess.ObjectBinding

Assembly: DevExpress.DataAccess.v20.1.dll

Declaration

[DefaultValue(null)]
public string DataMember { get; set; }
<DefaultValue(Nothing)>
Public Property DataMember As String

Property Value

Type Default Description
String

null

A String value, specifying the data member.

Remarks

To bind the ObjectDataSource to an object, leave this property set to null. In the Data Source wizard, this scenario corresponds to the following option: "Do not select a member, bind to the entire object".

To bind the ObjectDataSource to a property or method, assign its name to the DataMember property. When binding to a method, it is also required to specify this method's ObjectDataSource.Parameters.

See Also