Windows apps
Collapse the table of content
Expand the table of content
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Selector.IsSynchronizedWithCurrentItem Property


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Gets or sets a value that indicates whether a Selector should keep the SelectedItem synchronized with the current item in the Items property.

Namespace:   System.Windows.Controls.Primitives
Assembly:  PresentationFramework (in PresentationFramework.dll)

[TypeConverterAttribute("System.Windows.NullableBoolConverter, PresentationFramework, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35, Custom=null")]
public Nullable<bool> IsSynchronizedWithCurrentItem { get; set; }

Property Value

Type: System.Nullable<Boolean>

true if the SelectedItem is always synchronized with the current item in the ItemCollection; false if the SelectedItem is never synchronized with the current item; null if the SelectedItem is synchronized with the current item only if the Selector uses a CollectionView. The default value is null.

You can set the IsSynchronizedWithCurrentItem property to true to ensure that the item selected always corresponds to the CurrentItem property in the ItemCollection. For example, suppose that there are two ListBox controls with their ItemsSource property set to the same source. Set IsSynchronizedWithCurrentItem to true on both list boxes to ensure that the selected item in each ListBox is the same.

<object IsSynchronizedWithCurrentItem="Boolean"/>

- or -

<object IsSynchronizedWithCurrentItem="{}"/>

Identifier field


Metadata properties set to true


The following example binds two ListBox controls to the same ItemsSource. Because IsSynchronizedWithCurrentItem is set to true on each ListBox, the selected item is always the same for both controls

.NET Framework
Available since 3.0
Available since 3.0
Windows Phone Silverlight
Available since 7.0
Return to top
© 2018 Microsoft