xpo-devexpress-dot-xpo-dot-xpview-dot-addproperty-x28-system-dot-string-system-dot-string-x29.md
Creates a new ViewProperty object with the specified expression and appends it to the XPView.Properties collection.
Namespace : DevExpress.Xpo
Assembly : DevExpress.Xpo.v25.2.dll
NuGet Package : DevExpress.Xpo
public ViewProperty AddProperty(
string name,
string property
)
Public Function AddProperty(
name As String,
property As String
) As ViewProperty
| Name | Type | Description |
|---|---|---|
| name | String |
A String value which specifies the property name. This value is assigned to the ViewProperty.Name property.
| | property | String |
A String value which specifies the expression used to calculate the values in a column. This value is assigned to the ViewProperty.Property property.
|
| Type | Description |
|---|---|
| ViewProperty |
The ViewProperty object that was added to the collection.
|
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the AddProperty(String, String) method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-treelist-expression-editor-xpview/CS/E1887/Form1.cs#L25
input.ShowDialog();
xpView1.AddProperty(input.ColumnName, editor.Expression);
treeList1.PopulateColumns();
winforms-treelist-expression-editor-xpview/VB/E1887/Form1.vb#L25
input.ShowDialog()
xpView1.AddProperty(input.ColumnName, editor.Expression)
treeList1.PopulateColumns()
See Also