![]() ![]() ![]() (Events are optional, you can define "event-less" rules that you can call from other rules.) Events define when the rule should run, such as when a button is clicked, or when the form loads.A valid rule contains at least one action. Rules consist of events, conditions, and actions. Action: Show a message (move the action to the condition group add your own content).Condition: if the View passes Validation (validate all three text box controls show validation messages).(You can have inline validation as well as rules that validate the form after some event.) Edit the Pattern Sample view and add a new rule with the following configuration: The validation takes place after an event, such as when you click the button. In this step, you work with rule level validation. The previous tests demonstrate inline validation. Configure a rule to validate a control.Click the Pattern Sample view title in the category menu to close the test.Hover over the box and view the error message. Once again, refocus your cursor outside of the box. There is no error as the entry passes validation. Enter a standard format phone number and move the cursor to another control.Hover over the box to see the validation error message. (The validation takes place when you refocus your cursor away from the text box.) Notice the box now has a red border. Into the Phone Number Text Box and click outside of the box. Right-click the Pattern Sample view and select Run. In this test, you see the inline error messages that occur when a value does not match the pattern applied to the text box.Enter values that are not in the correct format for both the phone number and password. Click Finish (near the upper right corner of your screen) to save and exit. You are ready to test the two text boxes.(You just added the new pattern, but you still need to apply it to the Password Text Box.) You should see Complex Password as the Pattern value. Select the Complex Password pattern and click OK.The minimum allowed length is eight characters. Passwords must contain one uppercase letter, one lowercase letter, two numbers and one special character. Use the table below to configure the new password pattern. Add a new pattern and apply it to the Password Text Box control. Apply the Phone Number pattern to the Phone Number Text Box control. You add and apply a custom pattern to the Password Text Box control. In the next step, you apply a built-in pattern to the Phone Number Text Box control. Set the Name and Text properties for the remaining controls using the table below as a guide. ![]() The Text property is the value you see when you view loads. K2 uses the Name property to identify the control in the view and rules. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |