One of the disadventage I found in WPF is it doesnot have a Numeric UpDown control. So I make a listbox with height as 25 so that it will display only one item at a time and the vertical scroll feels like a UpDown controls. My problem is when I use the scroll to change the value, I can't get the current value shown in listbox. Can any idea to get the value shown in listbox without selecting it?
Asked
Active
Viewed 3,011 times
4 Answers
2
Though there's no standard WPF NumericUpDown, you can try NumericUpDown Custom Control with Theme and UI Automation Support Sample.

Helen
- 87,344
- 17
- 243
- 314
1
well since you are using WPF, you can change the template of your ListBoxItem and change it's look to nothing when the item is selected ( i mean remove the trigger ), that's all.
I hope it's helpful, unless you need other things than this.

abdelkarim
- 586
- 6
- 11
1
You can also attach a ScrollBar.Scroll event. This fires when you scroll. Maybe you can then change the SelectedIndex manually or set the focus?

rudigrobler
- 17,045
- 12
- 60
- 74