XPDataView.AddProperty(String, Type) Method
Creates a new DataViewProperty object with the specified name and type, and appends it to the XPDataView.Properties collection.
Namespace: DevExpress.Xpo
Assembly: DevExpress.Xpo.v24.2.dll
NuGet Package: DevExpress.Xpo
#Declaration
public DataViewProperty AddProperty(
string name,
Type valueType
)
#Parameters
Name | Type | Description |
---|---|---|
name | String | A String value which specifies the column name. This value is assigned to the Data |
value |
Type | A Type value which specifies the column’s type. This value is assigned to the Data |
#Returns
Type | Description |
---|---|
Data |
A Data |
#Remarks
Rather than adding individual columns to the collection via AddProperty, you can call the XPDataView.PopulateProperties or XPDataView.PopulatePropertiesOrdered method, to populate the collection with columns based on persistent properties of a specific object.