skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • NEW: Design Kits for Figma
    • Online Training
    • Document Processing Library
    • Embedded Reporting for web and desktop

    Web

    Kendo UI UI for jQuery UI for Angular UI for React UI for Vue UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Test Studio Dev Edition Telerik JustMock

    CMS

    Sitefinity

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    VB.NET to C# Converter Testing Framework
    View all products
  • Overview
  • Demos
    • What's New
    • Roadmap
    • Release History
  • Support and Learning

    • Support and Learning Hub
    • First Steps
    • Docs
    • Demos
    • Virtual Classroom
    • Forums
    • Videos
    • Blogs
    • Accessibility
    • Submit a Ticket

    Productivity and Design Tools

    • Visual Studio Extensions
    • Visual Studio Templates
    • Embedded Reporting
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class ListControl

Represents the list control that has multi-selection.

Inheritance
System.Object
ItemsControlSelector
ListControl
RadListBox
Inherited Members
ItemsControlSelector.SelectionModeProperty
ItemsControlSelector.IsSynchronizedWithCurrentItemProperty
ItemsControlSelector.SelectedIndexProperty
ItemsControlSelector.SelectedItemProperty
ItemsControlSelector.SelectedValueProperty
ItemsControlSelector.SelectedValuePathProperty
ItemsControlSelector.TextProperty
ItemsControlSelector.TextPathProperty
ItemsControlSelector.EnableSelectionCachingProperty
ItemsControlSelector.SelectionChangedEvent
ItemsControlSelector.ISelectorInteraction.IsItemSelectable(Object)
ItemsControlSelector.IsItemSelectable(Object)
ItemsControlSelector.ISelectorInteraction.GetItems()
ItemsControlSelector.GetDataItem(UIElement)
ItemsControlSelector.ISelectorInteraction.MoveCurrentItemInCollectionView(Object)
ItemsControlSelector.OnItemsSourceChanged(IEnumerable, IEnumerable)
ItemsControlSelector.OnItemsChanged(NotifyCollectionChangedEventArgs)
ItemsControlSelector.ChangeVisualState(Boolean)
ItemsControlSelector.OnIsEnabledChanged(DependencyPropertyChangedEventArgs)
ItemsControlSelector.InitializeValueRetriever()
ItemsControlSelector.InitializeTextRetriever()
ItemsControlSelector.UpdateItems(NotifyCollectionChangedAction, IList, IList)
ItemsControlSelector.InitializeSelectionBehavior()
ItemsControlSelector.GetSelectionBehavior()
ItemsControlSelector.EndInit()
ItemsControlSelector.ISelectorInteraction.IsDefaultCollectionView
ItemsControlSelector.SelectionMode
ItemsControlSelector.IsSynchronizedWithCurrentItem
ItemsControlSelector.SelectedItems
ItemsControlSelector.SelectionHelper
ItemsControlSelector.SelectedIndex
ItemsControlSelector.SelectedItem
ItemsControlSelector.SelectedValue
ItemsControlSelector.SelectedValuePath
ItemsControlSelector.SelectedValueBinding
ItemsControlSelector.TextBinding
ItemsControlSelector.Text
ItemsControlSelector.TextPath
ItemsControlSelector.EnableSelectionCaching
ItemsControlSelector.ItemSearch
ItemsControlSelector.ValueRetriever
ItemsControlSelector.TextRetriever
ItemsControlSelector.SelectionChanged
Namespace: Telerik.Windows.Controls.Primitives
Assembly: Telerik.Windows.Controls.dll

Syntax

public class ListControl : ItemsControlSelector, IMultiSelector, ISelector, ISelectorInteraction, IAutocomplete, IListControl, ICommandSource, IScrollingServiceCore, IScrollingInfo

Constructors

ListControl()

Initializes a new instance of the ListControl class.

Declaration
public ListControl()

Fields

CanAutocompleteSelectItemsProperty

Identifies the CanAutocompleteSelectItems dependency property.

Declaration
public static readonly DependencyProperty CanAutocompleteSelectItemsProperty
Field Value
System.Windows.DependencyProperty

CanAutocompleteSelectPartialMatchesProperty

Identifies the CanAutocompleteSelectPartialMatches dependency property.

Declaration
public static readonly DependencyProperty CanAutocompleteSelectPartialMatchesProperty
Field Value
System.Windows.DependencyProperty

CanKeyboardNavigationSelectItemsProperty

Identifies the CanListControlKeyboardNavigationSelectItems dependency property.

Declaration
public static readonly DependencyProperty CanKeyboardNavigationSelectItemsProperty
Field Value
System.Windows.DependencyProperty

CommandParameterProperty

Identifies the CommandParameter dependency property.

Declaration
public static readonly DependencyProperty CommandParameterProperty
Field Value
System.Windows.DependencyProperty

CommandProperty

Identifies the Command dependency property.

Declaration
public static readonly DependencyProperty CommandProperty
Field Value
System.Windows.DependencyProperty

CommandTargetProperty

Identifies the CommandTarget dependency property.

Declaration
public static readonly DependencyProperty CommandTargetProperty
Field Value
System.Windows.DependencyProperty

IsScrollIntoViewEnabledProperty

Identifies the IsScrollIntoViewOnSelectionEnabled dependency property. This property determines of the selected item will be automatically scrolled into the view.

Declaration
public static readonly DependencyProperty IsScrollIntoViewEnabledProperty
Field Value
System.Windows.DependencyProperty

TextSearchModeProperty

Identifies the TextSearchMode dependency property.

Declaration
public static readonly DependencyProperty TextSearchModeProperty
Field Value
System.Windows.DependencyProperty

TypedTextProperty

Identifies the TypedText dependency property.

Declaration
public static readonly DependencyProperty TypedTextProperty
Field Value
System.Windows.DependencyProperty

Properties

AutocompleteBehavior

Gets or sets the autocomplete behavior.

Declaration
protected AutocompleteBehavior AutocompleteBehavior { get; set; }
Property Value
AutocompleteBehavior

CanAutocompleteSelectItems

Gets or sets a value that specifies whether the autocomplete should select items, or not. This is a dependency property.

Declaration
public Nullable<bool> CanAutocompleteSelectItems { get; set; }
Property Value
System.Nullable<System.Boolean>

CanAutocompleteSelectPartialMatches

Gets or sets a value that specifies whether the autocomplete should select partially matching items, or not. This is a dependency property.

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

CanKeyboardNavigationSelectItems

Gets or sets the CanKeyboardNavigationSelectItems. This is a dependency property.

Declaration
public Nullable<bool> CanKeyboardNavigationSelectItems { get; set; }
Property Value
System.Nullable<System.Boolean>

Command

Gets or sets the Command. This is a dependency property.

Declaration
public ICommand Command { get; set; }
Property Value
System.Windows.Input.ICommand

CommandParameter

Gets or sets the CommandParameter. This is a dependency property.

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

CommandTarget

Gets or sets the CommandTarget. This is a dependency property.

Declaration
public IInputElement CommandTarget { get; set; }
Property Value
System.Windows.IInputElement

HighlightedIndex

Gets the index of the highlighted item.

Declaration
public int HighlightedIndex { get; }
Property Value
System.Int32

The index of the highlighted.

Implements
IListControl.HighlightedIndex

HighlightedItem

Gets or sets the highlighted item.

Declaration
protected object HighlightedItem { get; set; }
Property Value
System.Object

IsItemsHostVisible

Gets a value indicating whether the items host is visible. Override if a custom logic is required. Default value is true.

Declaration
protected virtual bool IsItemsHostVisible { get; }
Property Value
System.Boolean

IsScrollIntoViewEnabled

Gets or sets the IsScrollIntoViewEnabled. This is a dependency property.

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

KeyboardNavigation

Gets the keyboard navigation.

Declaration
protected KeyboardNavigation KeyboardNavigation { get; }
Property Value
KeyboardNavigation

SelectAllCommand

Gets the command that will be executed when select all. This is a RoutedUICommand.

Declaration
public static RoutedUICommand SelectAllCommand { get; }
Property Value
System.Windows.Input.RoutedUICommand

TextSearchMode

Gets or sets the text search mode. Specifies how TextSearch will match items. This is a dependency property.

Declaration
public TextSearchMode TextSearchMode { get; set; }
Property Value
TextSearchMode

The text search mode.

TypedText

Gets or sets the current typed text. This is a dependency property.

Declaration
public string TypedText { get; set; }
Property Value
System.String

Methods

CanPerformSelection()

Indicates whether the selection helper can perform operation or not.

Declaration
protected override bool CanPerformSelection()
Returns
System.Boolean

Returns true if the panel is not null, is not Grid and ItemContainerGenerator.Status is GeneratingContainers; otherwise false.

Overrides
ItemsControlSelector.CanPerformSelection()

ClearContainerForItemOverride(DependencyObject, Object)

Clears the values for SelectionHelper, ParentSelector and IsSelected properties.

Declaration
protected override void ClearContainerForItemOverride(DependencyObject element, object item)
Parameters
System.Windows.DependencyObject element

The ListItem container element.

System.Object item

The item.

ClearContainerStates(FrameworkElement)

Clears the properties that effect the visual states for the given container. This method is called in ClearContainerForItemOverride(DependencyObject, Object)

Declaration
protected virtual void ClearContainerStates(FrameworkElement container)
Parameters
System.Windows.FrameworkElement container

The container which is cleared for item override.

GetContainerForItemOverride()

Creates or identifies the element that is used to display the given item.

Declaration
protected override DependencyObject GetContainerForItemOverride()
Returns
System.Windows.DependencyObject

The element that is used to display the given item.

GetScrollViewerPart()

Called on initializing the ScrollViewer on template applied. It's mandatory to get the ScrollViewer in order to perform selection.

Declaration
protected virtual ScrollViewer GetScrollViewerPart()
Returns
System.Windows.Controls.ScrollViewer

The ScrollViewer instance in the control template.

Remarks

If there is no ScrollViewer in the control template, override the logic in CanPerformSelection() method.

HandleKeyboardInput(Key)

When overridden in a derived class, is invoked whenever application code or internal processes call HandleKeyboardInput(Key). Override this method if a custom keyboard navigation is required.

Declaration
protected virtual bool HandleKeyboardInput(Key key)
Parameters
System.Windows.Input.Key key

The key.

Returns
System.Boolean

HighlightedIndexChanged(Int32, Key)

Highlights the changed index.

Declaration
protected virtual void HighlightedIndexChanged(int index, Key key)
Parameters
System.Int32 index

System.Windows.Input.Key key

IsIndexSelectable(Int32)

Determines whether the index is selectable.

Declaration
protected override bool IsIndexSelectable(int index)
Parameters
System.Int32 index

The index.

Returns
System.Boolean

Overrides
ItemsControlSelector.IsIndexSelectable(Int32)

IsItemItsOwnContainerOverride(Object)

Determines if the specified item is (or is eligible to be) its own container.

Declaration
protected override bool IsItemItsOwnContainerOverride(object item)
Parameters
System.Object item

The item to check.

Returns
System.Boolean

True if the item is (or is eligible to be) its own container; otherwise, false.

OnApplyTemplate()

When overridden in a derived class, is invoked whenever application code or internal processes call System.Windows.FrameworkElement.ApplyTemplate.

Declaration
public override void OnApplyTemplate()
Overrides
ItemsControlSelector.OnApplyTemplate()

OnAutocompleteBehaviorTypedTextChanged()

Called when a text is typed.

Declaration
protected virtual void OnAutocompleteBehaviorTypedTextChanged()

OnItemsPanelChanged(ItemsPanelTemplate, ItemsPanelTemplate)

Invoked when the System.Windows.Controls.ItemsControl.ItemsPanel property changes.

Declaration
protected override void OnItemsPanelChanged(ItemsPanelTemplate oldItemsPanel, ItemsPanelTemplate newItemsPanel)
Parameters
System.Windows.Controls.ItemsPanelTemplate oldItemsPanel

Old value of the System.Windows.Controls.ItemsControl.ItemsPanel property.

System.Windows.Controls.ItemsPanelTemplate newItemsPanel

New value of the System.Windows.Controls.ItemsControl.ItemsPanel property.

OnMatchingItemChanged()

When overridden in a derived class, is invoked whenever application code or internal processes call OnMatchingItemChanged(). Called when matching item is changed. Override this method if a custom logic is required when an item is changed.

Declaration
protected virtual void OnMatchingItemChanged()

OnPropertyChanged(DependencyPropertyChangedEventArgs)

Declaration
protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e)
Parameters
System.Windows.DependencyPropertyChangedEventArgs e

OnSelectionChanged(SelectionChangedEventArgs)

Called when the selection changes.

Declaration
protected override void OnSelectionChanged(SelectionChangedEventArgs e)
Parameters
System.Windows.Controls.SelectionChangedEventArgs e

The event data.

Overrides
ItemsControlSelector.OnSelectionChanged(SelectionChangedEventArgs)

OnSelectionModeChanged()

Called when selection mode changed. Update CanAutocompleteSelectItems property.

Declaration
protected override void OnSelectionModeChanged()
Overrides
ItemsControlSelector.OnSelectionModeChanged()

PrepareContainerForItemOverride(DependencyObject, Object)

Prepares the specified element to display the specified item.

Declaration
protected override void PrepareContainerForItemOverride(DependencyObject element, object item)
Parameters
System.Windows.DependencyObject element

Element used to display the specified item.

System.Object item

Specified item.

ScrollIntoView(Int32)

Scrolls the into view.

Declaration
public void ScrollIntoView(int index)
Parameters
System.Int32 index

The index.

Implements
IListControl.ScrollIntoView(Int32)

ScrollIntoView(Object)

Scrolls the into view.

Declaration
public void ScrollIntoView(object item)
Parameters
System.Object item

Explicit Interface Implementations

IScrollingInfo.ExtentHeight

Declaration
double IScrollingInfo.ExtentHeight { get; }
Returns
System.Double

Implements
IScrollingInfo.ExtentHeight

IScrollingInfo.ExtentWidth

Declaration
double IScrollingInfo.ExtentWidth { get; }
Returns
System.Double

Implements
IScrollingInfo.ExtentWidth

IScrollingInfo.HorizontalOffset

Declaration
double IScrollingInfo.HorizontalOffset { get; }
Returns
System.Double

Implements
IScrollingInfo.HorizontalOffset

IScrollingInfo.TransformFromDropTargetToViewPort(Point)

Declaration
Point IScrollingInfo.TransformFromDropTargetToViewPort(Point positionInDropTarget)
Parameters
System.Windows.Point positionInDropTarget

Returns
System.Windows.Point

Implements
IScrollingInfo.TransformFromDropTargetToViewPort(Point)

IScrollingInfo.VerticalOffset

Declaration
double IScrollingInfo.VerticalOffset { get; }
Returns
System.Double

Implements
IScrollingInfo.VerticalOffset

IScrollingInfo.ViewportHeight

Declaration
double IScrollingInfo.ViewportHeight { get; }
Returns
System.Double

Implements
IScrollingInfo.ViewportHeight

IScrollingInfo.ViewportWidth

Declaration
double IScrollingInfo.ViewportWidth { get; }
Returns
System.Double

Implements
IScrollingInfo.ViewportWidth

IScrollingServiceCore.ScrollHorizontal(Double)

Declaration
void IScrollingServiceCore.ScrollHorizontal(double offsetX)
Parameters
System.Double offsetX

Implements
IScrollingServiceCore.ScrollHorizontal(Double)

IScrollingServiceCore.ScrollVertical(Double)

Declaration
void IScrollingServiceCore.ScrollVertical(double offsetY)
Parameters
System.Double offsetY

Implements
IScrollingServiceCore.ScrollVertical(Double)

IListControl.Items

Declaration
IList IListControl.Items { get; }
Returns
System.Collections.IList

Implements
IListControl.Items

Extension Methods

ItemsControlSelectorExtensions.ContainerFromItemOrContainer(ItemsControlSelector, Object)
ItemsControlSelectorExtensions.ContainerFromIndex(ItemsControlSelector, Int32)
CollectionExtensions.ToEnumerable<T>(T)
EnumerableExtensions.ToEnumerable<T>(T)
Getting Started
  • Install Now
  • Demos
  • SDK Samples Browser
  • Sample Applications
Support Resources
  • Code Library
  • Knowledge Base
  • MVVM Support
  • Videos
  • GitHub SDK Repository
Community
  • Forums
  • Blogs
  • XAML Feedback Portal
  • Document Processing Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.