microsoft / microsoft/microsoft-ui-xaml
ComboBox select the first item even if no SelectedIndex is set
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 8.4k
- Forks
- 942
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 105
Description
### Describe the bug
ComboBox will select the first item when opening the popup when no `SelectedIndex` is set. This is not an issue in WinUI2 and must have been a regression recently.
### Steps to reproduce the bug
WinUi3 Gallery:

Winui2 Gallery:

### Expected behavior
_No response_
### Screenshots
_No response_
### NuGet package version
WinUI 3 - Windows App SDK 1.7.3: 1.7.250606001
### Windows version
Windows 11 (24H2): Build 26100
### Additional context
_No response_
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the behavior in the WinUI 3 Gallery by opening a ComboBox popup without setting SelectedIndex, then compare it with the WinUI 2 Gallery shown in the report. Trace the ComboBox popup and selection behavior; done means the first item is not selected when no SelectedIndex is set, while explicit selection still works.
Written by the indexing model from the issue text.
Assessment
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100