---
title: "Q: Why should I bother wrapping items in a ComboBoxItem?"  
description: "Q: Why should I bother wrapping items in a ComboBoxItem?"  
author: "Anonymous User"  
published: 2011-03-11  
updated: 2020-09-20  
canonical: https://www.mindstick.com/interview/399/q-why-should-i-bother-wrapping-items-in-a-comboboxitem  
category: "wpf"  
tags: ["wpf"]  
reading_time: 2 minutes  

---

# Q: Why should I bother wrapping items in a ComboBoxItem?

ComboBoxItem exposes some useful properties—IsSelected andIsHighlighted—and\
useful events—Selected and Unselected. Using ComboBoxItem also avoids a quirkybehavior with showing content controls in the selection box (when IsEditable isfalse): If an item in a ComboBox is a content control, the entire controldoesn’t get displayed in the selection box. Instead, the inner content isextracted and shown. By using ComboBoxItem as the outermost content control,the inner content is now the entire control that you probably wanted to bedisplayed in the first place.\
Because ComboBoxItem is a content control, it is also handy for adding simplestrings to a\
ComboBox (rather than using something like TextBlock or Label).

## Answers

### Answer by Anonymous User

ComboBoxItem exposes some useful properties—IsSelected andIsHighlighted—and\
useful events—Selected and Unselected. Using ComboBoxItem also avoids a quirkybehavior with showing content controls in the selection box (when IsEditable isfalse): If an item in a ComboBox is a content control, the entire controldoesn’t get displayed in the selection box. Instead, the inner content isextracted and shown. By using ComboBoxItem as the outermost content control,the inner content is now the entire control that you probably wanted to bedisplayed in the first place.\
Because ComboBoxItem is a content control, it is also handy for adding simplestrings to a\
ComboBox (rather than using something like TextBlock or Label).


---

Original Source: https://www.mindstick.com/interview/399/q-why-should-i-bother-wrapping-items-in-a-comboboxitem

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
