add NumericUpDownPlus style
now you can clear, verify the value of NumericUpDown
This commit is contained in:
1 parent
53bfd7da17
commit
0b80e7ddec
36 files changed
+602
-76
No files matched your search
@@ -1,4 +1,6 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
using HandyControl.Data;
|
||||
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace HandyControlDemo.UserControl
|
||||
{
|
||||
public partial class NumericUpDownDemoCtl
|
||||
@@ -6,6 +8,12 @@ namespace HandyControlDemo.UserControl
|
||||
public NumericUpDownDemoCtl()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
NumericUpDownCustomVerify.VerifyFunc = str => double.TryParse(str, out var v)
|
||||
? v % 2 < 1e-06
|
||||
? OperationResult.Failed(Properties.Langs.Lang.Error)
|
||||
: OperationResult.Success()
|
||||
: OperationResult.Failed(Properties.Langs.Lang.Error);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user