Is it possible to validate during a input?
[Modified 11 years ago]
Is it possible to validate during a input?
[Modified 11 years ago]
Hi,
Yes please take a look at the "Data Validation" QuickStart and documentation topic. Those describe how to do so.
I can't find any samples
Hello, the samples are installed with the product when you run the installer on you machine. You can get to the sample project from the Windows all programs menu. There will be a group of links for Actipro WPF Controls.
I can't find any samples in the QuickStart or documentation.
Hello,
Both the "Data Validation" QuickStart and "Data Validation" documentation topic talk about and/or show how to validate the results of what an end user commits as a value.
Hello.
I'am working on the same issue as snupru and can't find any sample, too.
I tried to validate an input in the PropertyGrid on KeyUp-Event (while typing)
The QuickStart only show's validation when a end user commits a value.
Is there the possibility to handle/catch this event?
Hello, that is correct, the PropertyGrid validation is based around what is committed to the properties being edited.
If you want to validate while the end user is typing, that would be more of a function of the property editor in use for editing the property. You can make custom property editors (also shown in the samples and documentation) that could use custom controls for input. Then in those custom controls, you could block certain characters from being typed such as with KeyDown.
The only other thing you could do is if you have our default styles/templates, you could clone them and change the property editor template for the one you need here to bind the editor control (textbox, or whatever it is in the template) to have the binding UpdateSourceTrigger be on PropertyChanged instead of LostFocus. That way our PropertyGrid validation code would kick in as the user types.
Please log in to a validated account to post comments.