Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
335
XamNumericEditor with double, minimum and maximum
posted

Hello,

I'm not able to find the solution of this. I would like to have a XamNumericEditor where the data type is double and the minimum/maximum can be set.

I use NetAdvantage WPF 2012.2. The documentation say there are Minimum and Maximum properties (http://help.infragistics.com/Help/NetAdvantage/Silverlight/2012.1/CLR4.0/html/InfragisticsSL5.Controls.Editors.v12.1~Infragistics.Controls.Editors.XamNumericEditor_members.html). But with "2012.2" there aren't such kind of properties.

So I tried to set it with "Mask" (http://help.infragistics.com/Help/NetAdvantage/WPF/2011.1/CLR4.0/html/xamEditors_Masks.html) in this way:

                        <igWPF:XamNumericEditor x:Name="MyEditor" Grid.Row="1" Grid.Column="2" Width="80"
                                                SpinButtonDisplayMode="Always"
                                                Theme="IGTheme"
                                                Value="0"
                                                Mask="{}{double:4.1}{number:0-255}">

But this doesn't work.

The requirements are as follow:

- The data type should be double and min/max are set to the XamNumericEditor.

- If the user sets a higher value than the maximum, XamNumericEditor should clip the value to the maximum.

- If the user sets a lower value than the minimum, XamNumericEditor should clip the value to the minimum.

- The validation process should start after the user clicks the enter key.

Please have a look at the attached project, where I tried to implement these requirements into the "X Axis Display Maximum and Minimum". You can try it be setting the Maximum x Display value to 9999. The value should be clipped to 850.

Who can help me in this case?

Regards,

Thomas



Validation.zip
Parents Reply Children