This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Hello, I'm using WPFElements version 5.1 and I found a crash of the property grid by trying to edit the 'FontSize' when the selected objects are two or more 'System.Windows.Controls.Button controls', and the FontSize of the objects are different. In this case when I click on the button of the 'FontSize' row I have the following exception and call stack: An unhandled exception of type 'System.ArgumentException' occurred in WindowsBase.dll Additional information: '0' is not a valid value for property 'FontSize'. If there is a handler for this exception, the program may be safely continued. WindowsBase.dll!System.Windows.DependencyObject.SetValueCommon(System.Windows.DependencyProperty dp, object value, System.Windows.PropertyMetadata metadata, bool coerceWithDeferredReference, bool coerceWithCurrentValue, System.Windows.OperationType operationType, bool isInternal) + 0x64a bytes I enclosed a sample project in order to reproduce the problem: 1) Open and compile the project with VS2012 2) Run the project 3) Try to edit the 'FontSize' property. Any one have the same problem and have found a solution ? Thank you, Maurizio Zaniboni |
|
|
Hello Maurizio Thanks for pointing this out! I've updated the PropertyGrid to handle this by resetting the value to the default property value (for FontSize this is 12) rather than the default type value (which was 0 for double). This is the safest way to handle this scenario. This update will be available in the next nightly build. The next nightly build will be available at around 1200 GMT which you'll be able to download from here: http://www.mindscapehq.com/products/wpfelements/nightly-builds Jason Fauchelle |
|