aspnet-devexpress-dot-web-dot-aspxautocompleteboxbase-3c7614ee.md
Gets the collection of editor items.
Namespace : DevExpress.Web
Assembly : DevExpress.Web.v25.2.dll
NuGet Package : DevExpress.Web
public virtual ListEditItemCollection Items { get; }
Public Overridable ReadOnly Property Items As ListEditItemCollection
| Type | Description |
|---|---|
| ListEditItemCollection |
A collection of editor items.
|
Use the Items property to access the editor’s item collection. The property is not in effect if the editor is bound to data.
Note that item values (Value) must be unique.
View Example: Combo Box for ASP.NET Web Forms - How to get hidden column values on the client
<dx:ASPxComboBox ID="ASPxComboBox1" ClientInstanceName="cbox" ValueField="ProductID" DropDownStyle="DropDownList"
OnCustomJSProperties="ASPxComboBox1_CustomJSProperties" DataSourceID="SqlDataSource1" runat="server" Width="300">
<Columns>
<dx:ListBoxColumn FieldName="ProductID" />
<dx:ListBoxColumn FieldName="ProductName" />
<dx:ListBoxColumn FieldName="CategoryID" />
<dx:ListBoxColumn FieldName="UnitPrice" Visible="false" />
</Columns>
</dx:ASPxComboBox>
<dx:ASPxButton ID="ASPxButton1" runat="server" Text="UnitPrice value" AutoPostBack="false">
<ClientSideEvents Click="function(s, e) {
var v = cbox.cpHiddenColumnValues[cbox.GetSelectedIndex()];
alert(v);
}" />
</dx:ASPxButton>
protected void ASPxComboBox1_CustomJSProperties(object sender, DevExpress.Web.CustomJSPropertiesEventArgs e)
{
ArrayList list = new ArrayList();
foreach (ListEditItem item in ASPxComboBox1.Items)
list.Add(item.GetFieldValue("UnitPrice"));
e.Properties["cpHiddenColumnValues"] = list;
}
Protected Sub ASPxComboBox1_CustomJSProperties(ByVal sender As Object, ByVal e As DevExpress.Web.CustomJSPropertiesEventArgs)
Dim list As New ArrayList()
For Each item As ListEditItem In ASPxComboBox1.Items
list.Add(item.GetFieldValue("UnitPrice"))
Next item
e.Properties("cpHiddenColumnValues") = list
End Sub
See Also