ItemsControl.IsTextSearchCaseSensitive Property
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Gets or sets a value that indicates whether case is a condition when searching for items.
Namespace: System.Windows.Controls
Assembly: PresentationFramework (in PresentationFramework.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation
When the IsTextSearchEnabled property is set to true, the IsTextSearchCaseSensitive property specifies whether the case determines whether an item is selected in an ItemsControl. For example, if an ItemsControl contain two strings that differ only in case, such as "ITEM" and "item", the first string will always be selected, regardless of the case of the input.
The following example creates a ComboBox that contains the strings, "DOG", "CAT", "dog", and "cat". The example binds the IsTextSearchCaseSensitive property to the IsChecked property of a CheckBox. If the check box is selected and the user types "dog", the third item in the ItemsControl is selected. If the user unselects the check box and types "dog", the first item is selected because case is not a condition of the search.
<StackPanel> <CheckBox Content="_Case sensitive Search" IsChecked="True" Name="caseSensitiveSearch"/> <ComboBox IsEditable="True" IsTextSearchCaseSensitive="{Binding ElementName=caseSensitiveSearch, Path=IsChecked}"> <ComboBoxItem>DOG</ComboBoxItem> <ComboBoxItem>CAT</ComboBoxItem> <ComboBoxItem>dog</ComboBoxItem> <ComboBoxItem>cat</ComboBoxItem> </ComboBox> </StackPanel>
Windows 8 Consumer Preview, Windows Server 8 Beta, Windows 7, Windows Server 2008 SP2, Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.