Quantcast
Channel: Extended WPF Toolkit™ Community Edition
Viewing all articles
Browse latest Browse all 4964

Commented Unassigned: [IntegerUpDown] InvalidOperationException thrown on double-click when IsEnabled=false [19762]

$
0
0
If you double-click on an IntegerUpDown when it is disabled, it will throw an InvalidOperationException stating: 'EditItem' is not allowed for this view.

Steps:
1. On an IntegerUpDown control in XAML, set IsEnabled="False" on the control.
2. Run your application in debug mode.
3. In the window that contains the control, double-click on the control. Observe the exception that is thrown.

I was using both IsEnable=false and IsReadOnly=true when I stumbled upon this bug. IsReadOnly=true allows the control to not be edited, and IsEnabled=false grays out the control. You only need to set IsEnabled=false to reproduce this bug. I believe it is a valid configuration to want the control set to read only AND have it grayed out. If it is grayed out, it tells the user it cannot be edited.
Comments: ** Comment from web user: michael_yanni **

Yup. Problem solved. I set IsReadOnly=True for the DataGrid that the control is on, and the exception doesn't occur anymore. Please, close this issue.


Viewing all articles
Browse latest Browse all 4964

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>