Base:
property
Count
System.Windows.Data.CollectionView.Count
Implemented interface member:
136 references to Count
Microsoft.VisualStudio.LanguageServices (1)
ChangeSignature\ChangeSignatureDialog.xaml.cs (1)
248if (oldSelectedIndex >= 0 && oldSelectedIndex < Members.Items.Count - 1)
PresentationFramework (76)
System\Windows\Automation\Peers\DataGridAutomationPeer.cs (2)
140return this.OwningDataGrid.Items.Count; 146if (row >= 0 && row < this.OwningDataGrid.Items.Count &&
System\Windows\Automation\Peers\GridViewAutomationPeer.cs (5)
37_oldItemsCount = _listview.Items.Count; 98if (_oldItemsCount != _listview.Items.Count) 100peer.RaisePropertyChangedEvent(GridPatternIdentifiers.RowCountProperty, _oldItemsCount, _listview.Items.Count); 102_oldItemsCount = _listview.Items.Count; 186get { return _listview.Items.Count; }
System\Windows\Automation\Peers\ItemAutomationPeer.cs (1)
354size = itemCollection.Count;
System\Windows\Automation\Peers\ItemsControlAutomationPeer.cs (5)
129else if (items.Count > 0) 255if (items != null && items.Count > 0) 278if (startIndex == 0 || startIndex == items.Count) 284for (int i = startIndex; i < items.Count; i++) 296for (int i = startIndex; i < items.Count; i++)
System\Windows\Automation\Peers\MenuItemAutomationPeer.cs (3)
170if (items.Count > 0) 172children = new List<AutomationPeer>(items.Count); 173for (int i = 0; i < items.Count; i++)
System\Windows\Automation\Peers\SelectorAutomationPeer.cs (1)
88int itemsCount = (owner as ItemsControl).Items.Count;
System\Windows\Automation\Peers\TreeViewAutomationPeer.cs (3)
68if (items.Count > 0) 70children = new List<AutomationPeer>(items.Count); 71for (int i = 0; i < items.Count; i++)
System\Windows\Controls\ComboBox.cs (3)
1533int count = Items.Count; 1550SelectItemHelper(0, +1, Items.Count); 1555SelectItemHelper(Items.Count - 1, -1, -1);
System\Windows\Controls\DataGrid.cs (19)
1800if (rowIndex < (Items.Count - 1)) 2647indexToSelect = Math.Min(Items.Count - numSelected - 1, indexToSelect); 2728index = Items.Count - 2; 2737if (index < Items.Count && ItemsControl.EqualsEx(newItem, Items[index])) 3820int itemCount = Items.Count; 3828if (Items.Count > 0) 3839int itemsCount = Items.Count; 4356int numItems = Items.Count; 4389int numItems = Items.Count; 5653(e.Key == Key.Down && currentRowIndex == Items.Count - 1)) 5785nextRowIndex = Items.Count - 1; 5811nextRowIndex = Math.Max(0, Items.Count - 1); 5816if (nextRowIndex >= Items.Count) 5990int numItems = Items.Count; 6068if ((_columns.Count > 0) && (Items.Count > 0)) 6096ItemInfo info = controlModifier ? ItemInfoFromIndex(homeKey ? 0 : Items.Count - 1) : CurrentInfo; 6141targetIndex = Math.Max(0, Math.Min(targetIndex, Items.Count - 1)); 6423for (int i = (isGrouping ? Items.Count - 1 : itemsHost.Children.Count - 1); i >= 0; i--) 6472for (int i = (isGrouping ? Items.Count - 1 : itemsHost.Children.Count - 1); i >= 0; i--)
System\Windows\Controls\HeaderedItemsControl.cs (2)
344itemCount = HasItems ? Items.Count : 0; 355itemCount = HasItems ? Items.Count : 0;
System\Windows\Controls\ItemContainerGenerator.cs (1)
894object target = (Parent == null) && (0 <= index && index < Host.View.Count) ? Host.View[index] : null;
System\Windows\Controls\ItemsControl.cs (2)
2597int count = Items.Count; 3997int itemsCount = HasItems ? Items.Count : 0;
System\Windows\Controls\Menu.cs (1)
342for (int i = 0; i < Items.Count; i++)
System\Windows\Controls\MenuItem.cs (2)
623for (int i = 0; i < menuItem.Items.Count; i++) 2354int count = parent.Items.Count;
System\Windows\Controls\Primitives\DataGridRowHeader.cs (1)
648dataGrid.CanUserResizeRows && dataGrid.Items.Count > 1 &&
System\Windows\Controls\Primitives\MenuBase.cs (1)
684int itemsCount = menu.Items.Count;
System\Windows\Controls\Primitives\Selector.cs (6)
353if ((value is int) && (int) value >= s.Items.Count) 405if ( (selectedIndex > -1 && selectedIndex < s.Items.Count && s.Items[selectedIndex] == value) 1222for (int i = 0; i < Items.Count; i++) 1712if ((selectedIndex > Items.Count - 1) 1986for (int i=0; unknownCount > 0 && i<Items.Count; ++i) 2447for (int index = 0; _toSelect.UnresolvedCount > 0 && index < _owner.Items.Count; ++index)
System\Windows\Controls\TabControl.cs (6)
80for (int i = 0; i < tabItemCollection.Count; i++) 392if (startIndex > Items.Count) 432startIndex = Items.Count; 453for (int i = 0; i < Items.Count; i++) 456if (index >= Items.Count) 459index = Items.Count - 1;
System\Windows\Controls\TextSearch.cs (1)
378int count = itemCollection.Count;
System\Windows\Controls\TreeViewItem.cs (1)
1035for (int i = 0, count = item.Items.Count; i < count; i++)
System\Windows\Controls\VirtualizedCellInfoCollection.cs (9)
155int numItems = items.Count; 979int numItems = _owner.Items.Count; 1008int numItems = _owner.Items.Count; 1064int numItems = _owner.Items.Count; 1152int numItems = _owner.Items.Count; 1196int numItems = _owner.Items.Count; 1234RemoveRegion(0, columnIndex, _owner.Items.Count, 1, ref removedRegions); 1255int numItems = _owner.Items.Count; 1611(rowIndex < owner.Items.Count) && (columnIndex < owner.Columns.Count))
System\Windows\Controls\VirtualizingStackPanel.cs (1)
12358"Items:", ic.Items.Count,
System.Windows.Controls.Ribbon (59)
Microsoft\Windows\Controls\Ribbon\Primitives\RibbonTabHeadersPanel.cs (1)
721int groupHeaderCount = groupHeaderItemsControl.Items.Count;
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (6)
1501int itemCount = ribbon.Items.Count; 1538if (SelectedIndex < 0 && Items.Count > 0) 1562int itemCount = Items.Count; 1672int itemCount = Items.Count; 1989tab.Items.Count, 2040quickAccessToolBar.Items.Count,
Microsoft\Windows\Controls\Ribbon\RibbonComboBox.cs (2)
1049handled = RibbonHelper.NavigateToPreviousMenuItemOrGallery(this, Items.Count, BringIndexIntoView); 1070handled = RibbonHelper.NavigateToPreviousMenuItemOrGallery(this, Items.Count, BringIndexIntoView);
Microsoft\Windows\Controls\Ribbon\RibbonContextualTabGroup.cs (2)
458for (int i = 0; i < Ribbon.Items.Count; i++) 521int itemCount = ribbon.Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonContextualTabGroupItemsControl.cs (2)
99return RibbonHelper.FindContainer(this, Items.Count - 1, -1, null, HasTabs) as RibbonContextualTabGroup; 256int count = this.Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonControlGroup.cs (2)
85for (int i = 0; i < Items.Count; i++) 102int itemCount = controlGroup.Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonGallery.cs (9)
593for (int i = 0; i < Items.Count; i++) 974for (int i = 0; i < Items.Count; i++ ) 1167if (category != null && category.Items.Count > 0) 1437for (int index=0; index<category.Items.Count; index++) 2154for (int index = 0; index < category.Items.Count; index++) 2219for (int index = 0; index < category.Items.Count; index++) 2318for (int i = 0; i < this.Items.Count; i++) 2355for (int i = 0; i < gallery.Items.Count; i++) 2530for (int index = 0; index < gallery.Items.Count; index++)
Microsoft\Windows\Controls\Ribbon\RibbonGroup.cs (6)
502if (Items.Count > 3) 532else if (Items.Count == 3) 552else if (Items.Count == 2) 841if (Items.Count == 0) 858for (int i = 0; i < Items.Count; i++) 1216int itemCount = Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonHelper.cs (19)
551FrameworkElement lastItem = FindContainer(itemsControl, itemsControl.Items.Count - 1, -1, bringIntoViewCallback, additionalCheck); 564int count = itemsControl.Items.Count; 588if (itemIndex < parent.Items.Count) 602if (startIndex == parent.Items.Count - 1) 605if (startIndex < parent.Items.Count - 1) 632startIndex = parent.Items.Count; 658RibbonGalleryCategory lastCategory = RibbonHelper.FindContainer(gallery, gallery.Items.Count - 1, -1, null, IsContainerVisible) as RibbonGalleryCategory; 770category = gallery.Items.Count > 0 ? gallery.ItemContainerGenerator.ContainerFromIndex(0) as RibbonGalleryCategory : null; 771galleryItem = category != null && category.Items.Count > 0 ? category.ItemContainerGenerator.ContainerFromIndex(0) as RibbonGalleryItem : null; 788endCatIndex = gallery.Items.Count; 809startItemIndex = galleryItem != null ? category.ItemContainerGenerator.IndexFromContainer(galleryItem) : category.Items.Count - 1; 832startColumnIndex = (galleryItem != null ? startItemIndex : category.Items.Count - 1) % columnCount; 839endItemIndex = category.Items.Count; 861int remainingItems = category.Items.Count; 901int remainingItems = category.Items.Count - itemIndex; 1929else if (menuItem.Items.Count == 0) 1940if (menuItem.Items.Count == 0) 2246for (int i = 0; i < originalItemsControl.Items.Count; i++) 2488int parentItemCount = parentItemsControl.Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonMenuButton.cs (1)
859handled = RibbonHelper.NavigateToPreviousMenuItemOrGallery(this, Items.Count, BringIndexIntoView);
Microsoft\Windows\Controls\Ribbon\RibbonQuickAccessToolBar.cs (1)
580int itemCount = QuickAccessToolBar.Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonTab.cs (5)
361_groupAutoResizeIndex = Items.Count - 1; 552_groupAutoResizeIndex = Items.Count - 1; 578_groupAutoResizeIndex = Items.Count - 1; 585if (numAttempts == Items.Count) 785int itemCount = Items.Count;
Microsoft\Windows\Controls\Ribbon\RibbonTabHeaderItemsControl.cs (1)
133ArgumentOutOfRangeException.ThrowIfGreaterThanOrEqual(index, Items.Count);
Microsoft\Windows\Controls\TextSearchInternal.cs (2)
138int itemCount = _attachedTo.Items.Count; 381int count = itemCollection.Count;