menu

ASP.NET Core - EJ2

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class DropDownList - ASP.NETCore-EJ2 API Reference | Syncfusion

    Show / Hide Table of Contents

    Class DropDownList

    Inheritance
    System.Object
    Syncfusion.EJ2.EJTagHelper
    DropDownList
    Namespace: Syncfusion.EJ2.DropDowns
    Assembly: Syncfusion.EJ2.dll
    Syntax
    public class DropDownList : EJTagHelper

    Constructors

    DropDownList()

    Declaration
    public DropDownList()

    Properties

    ActionBegin

    Triggers before fetching data from the remote server.

    Declaration
    public string ActionBegin { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    ActionComplete

    Triggers after data is fetched successfully from the remote server.

    Declaration
    public string ActionComplete { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    ActionFailure

    Triggers when the data fetch request from the remote server fails.

    Declaration
    public string ActionFailure { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    ActionFailureTemplate

    Accepts the template and assigns it to the popup list content of the component when the data fetch request from the remote server fails.

    Declaration
    public string ActionFailureTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "Request failed"

    AllowFiltering

    When allowFiltering is set to true, show the filter bar (search box) of the component. The filter action retrieves matched items through the filtering event based on the characters typed in the search TextBox.

    Declaration
    public bool AllowFiltering { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    AllowObjectBinding

    Defines whether the object binding is allowed or not in the component.

    Declaration
    public bool AllowObjectBinding { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    AllowResize

    Gets or sets a value that indicates whether the DropDownList popup can be resized. When set to true, a resize handle appears in the bottom-right corner of the popup, allowing the user to resize the width and height of the popup.

    Declaration
    public bool AllowResize { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    BeforeOpen

    Triggers when the popup before opens.

    Declaration
    public string BeforeOpen { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Blur

    Triggers when focus moves out from the component.

    Declaration
    public string Blur { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Change

    Declaration
    public string Change { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Close

    Triggers when the popup is closed.

    Declaration
    public string Close { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Created

    Triggers when the component is created.

    Declaration
    public string Created { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    CssClass

    Sets CSS classes to the root element of the component that allows customization of appearance.

    Declaration
    public string CssClass { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    DataBound

    Triggers when data source is populated in the popup list..

    Declaration
    public string DataBound { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    DataSource

    Accepts the list items either through local or remote service and binds it to the component. It can be an array of JSON Objects or an instance of DataManager.

    Declaration
    public object DataSource { get; set; }
    Property Value
    Type Description
    System.Object

    The default value is null

    Destroyed

    Triggers when the component is destroyed.

    Declaration
    public string Destroyed { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Enabled

    Specifies a value that indicates whether the component is enabled or not.

    Declaration
    public bool Enabled { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is true

    EnablePersistence

    Enable or disable persisting component's state between page reloads. If enabled, following list of states will be persisted.

    1. value
    Declaration
    public bool EnablePersistence { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    EnableRtl

    Enable or disable rendering component in right to left direction.

    Declaration
    public bool EnableRtl { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    EnableVirtualization

    Defines whether to enable virtual scrolling in the component.

    Declaration
    public bool EnableVirtualization { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    Fields

    The fields property maps the columns of the data table and binds the data to the component. text - Maps the text column from data table for each list item. value - Maps the value column from data table for each list item. iconCss - Maps the icon class column from data table for each list item. groupBy - Group the list items with it's related items by mapping groupBy field.

    Declaration
    public DropDownListFieldSettings Fields { get; set; }
    Property Value
    Type Description
    DropDownListFieldSettings

    The default value is null

    FilterBarPlaceholder

    Accepts the value to be displayed as a watermark text on the filter bar.

    Declaration
    public string FilterBarPlaceholder { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Filtering

    Declaration
    public string Filtering { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    FilterType

    Determines on which filter type, the component needs to be considered on search action. The FilterType and its supported data types are

    Declaration
    public FilterType FilterType { get; set; }
    Property Value
    Type Description
    FilterType

    The default value is FilterType.StartsWith

    FloatLabelType

    Specifies whether to display the floating label above the input element. Possible values are: Never: The label will never float in the input when the placeholder is available. Always: The floating label will always float above the input. Auto: The floating label will float above the input after focusing or entering a value in the input.

    Declaration
    public FloatLabelType FloatLabelType { get; set; }
    Property Value
    Type Description
    FloatLabelType

    The default value is Syncfusion.EJ2.Inputs.FloatLabelType.Never

    Focus

    Triggers when the component is focused.

    Declaration
    public string Focus { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    FooterTemplate

    Declaration
    public string FooterTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    For

    Declaration
    public override ModelExpression For { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExpression
    Overrides
    Syncfusion.EJ2.EJTagHelper.For

    GroupTemplate

    Accepts the template design and assigns it to the group headers present in the popup list.

    Declaration
    public string GroupTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    HeaderTemplate

    Declaration
    public string HeaderTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    HtmlAttributes

    Allows additional HTML attributes such as title, name, etc., and accepts n number of attributes in a key-value pair format.

    Declaration
    public object HtmlAttributes { get; set; }
    Property Value
    Type Description
    System.Object

    The default value is null

    IgnoreAccent

    ignoreAccent set to true, then ignores the diacritic characters or accents when filtering.

    Declaration
    public bool IgnoreAccent { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is null

    IgnoreCase

    When set to ‘false’, consider the case-sensitive on performing the search to find suggestions. By default consider the casing.

    Declaration
    public bool IgnoreCase { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is true

    Index

    Gets or sets the index of the selected item in the component.

    Declaration
    public double Index { get; set; }
    Property Value
    Type Description
    System.Double

    The default value is Double.NaN

    IsDeviceFullScreen

    Defines whether the popup opens in fullscreen mode on mobile devices when filtering is enabled. When set to false, the popup will display similarly on both mobile and desktop devices.

    Declaration
    public bool IsDeviceFullScreen { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is true

    ItemTemplate

    Accepts the template design and assigns it to each list item present in the popup. We have built-in template engine

    Declaration
    public string ItemTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Locale

    Overrides the global culture and localization value for this component. Default global culture is 'en-US'.

    Declaration
    public string Locale { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "en-US"

    NoRecordsTemplate

    Accepts the template design and assigns it to popup list of component when no data is available on the component.

    Declaration
    public string NoRecordsTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "No records found"

    Open

    Triggers when the popup opens.

    Declaration
    public string Open { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Placeholder

    Specifies a short hint that describes the expected value of the DropDownList component.

    Declaration
    public string Placeholder { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    PopupHeight

    Declaration
    public string PopupHeight { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "300px"

    PopupWidth

    Declaration
    public string PopupWidth { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "100%"

    Query

    Accepts the external Query that execute along with data processing.

    Declaration
    public string Query { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Readonly

    When set to true, the user interactions on the component are disabled.

    Declaration
    public bool Readonly { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    ResizeStart

    Triggers when the user starts resizing the DropDown popup.

    Declaration
    public string ResizeStart { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    ResizeStop

    Triggers when the user finishes resizing the DropDown popup.

    Declaration
    public string ResizeStop { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Resizing

    Triggers continuously while the DropDown popup is being resized by the user. This event provides live updates on the width and height of the popup.

    Declaration
    public string Resizing { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Select

    Triggers when an item in the popup is selected by the user either with mouse/tap or with keyboard navigation.

    Declaration
    public string Select { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    ShowClearButton

    Declaration
    public bool ShowClearButton { get; set; }
    Property Value
    Type
    System.Boolean

    SortOrder

    Specifies the sortOrder to sort the data source. The available type of sort orders are None - The data source is not sorting. Ascending - The data source is sorting with ascending order. Descending - The data source is sorting with descending order.

    Declaration
    public object SortOrder { get; set; }
    Property Value
    Type Description
    System.Object

    The default value is null

    Text

    Gets or sets the display text of the selected item in the component.

    Declaration
    public string Text { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Value

    Gets or sets the value of the selected item in the component.

    Declaration
    public object Value { get; set; }
    Property Value
    Type Description
    System.Object

    The default value is null

    ValueTemplate

    Declaration
    public string ValueTemplate { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Width

    Specifies the width of the component. By default, the component width sets based on the width of its parent container. You can also set the width in pixel values.

    Declaration
    public string Width { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "100%"

    ZIndex

    specifies the z-index value of the component popup element.

    Declaration
    public double ZIndex { get; set; }
    Property Value
    Type Description
    System.Double

    The default value is 1000

    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved