I've noticed in the Maintain Online Help - under the topic Validation Property - that there is a Validation Wizard that has been documented as "under development". Has anyone heard of this feature, or have any idea on its release - the "under development" dates back to 4.3 and is still included in the 5.2 documentation.
The property is still not used. I don't know the history of the feature, but do know that in 5.2 we actually do have automatic validation available from Update Assist generated applications. These use a validation library that is packaged with the WebFOCUS Client, which the Maintain group developed, called ibiValidate.
If you use the Update Assist wizard to generate an app, the app automatically uses the validation library. IN the future you will be able to associate validation with any INPUT box. Combos and lists, of course, do not require validation.
--Bob Jude Ferrante
WebFOCUS Maintain Products
Thanks for the reply Bob.
Its a nice feature with Update Assist, however our Maintain Applications are too complex to really utilize that feature. We were hoping for the Validation Wizard to come along, and save the need for scripting validations on all our forms.
The library is officially unsupported outside Update Assist, BUT...
The validation capability used in Update Assist is available to any Maintain form in any release higher than 5.2.0. The validation as coded checks to make sure user input in text boxes conforms to the WebFOCUS format. And if the entry is a date, it also checks to make sure a correct date has been entered.
To enable the validation and test it out, do the following:
Set the ibi format for the field. Whether validation works on a particular INPUT control is based on whether the control has an ibi format assigned. Assigning the IBI format is done by the server automatically if the field is BOUND to a stack or the current area and that field's format is known via a WebFOCUS master file description. The ibiformat can be set manually at design time but it must be done carefully, in the form XML, as it is not exposed to the developer in the MDE. It gets added to the BINDINGS island in the XML that describes each control. If you were going to manually set it up, you'd do the following for the control (add the code *without* the chevrons which I added as highlights).
>>> ibiformat="A0" <<<
2. Add the event handler to fire off validation. Example, if you want validation to occur on a control "blur" (loss of focus to the control) then add this code to the text box's onBlur event handler:
Substitute the NAME of the control for "name." The name must be in quotes.
The validate function is contained in a library called ibiValidate and the library is automatically invoked when a Maintain form is generated.
|Powered by Social Strata|