Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
19 replies
Subscribers
8 subscribers
Views
11377 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
User Interface
Validations
niharikas931
over 7 years ago
Hi,
I was trying to put a form validation on click of a button i.e a!buttonWidgetSubmit but that interface is called by wrapper interface that implemented 'Choose' function to break down the interface into sections.
The validation works as expected for the first time, it appears after clicking on submit button but if I go back and forth in that form, and come back to interface where the validation is applied, the validation message is showing even though I havent click on the Submit button.
I tried creating a local Boolean variable and reset when submit button is clicked. In validation, I was checking for that variable to show the validation message but it is not working.
Could you suggest anything that will work in this case.
OriginalPostID-237292
Discussion posts and replies are publicly visible
0
Colton Beck
over 7 years ago
Could it just be a form-level validation that displays if the validation criteria are true? Why the need to hide this until the user is ready to submit the form?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
niharikas931
over 7 years ago
if user go back and come back to same page, validation msg should disappear and only appear if he click on submit button again.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Colton Beck
over 7 years ago
Understood. Maybe I don't understand the full use case, but I'm just wondering why it's necessary to delay validation until users select the submit button.
If you know that the users will not be able to submit prior to them selecting the submit button, wouldn't it be better to notify them before the spend time entering data they won't be able to submit?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
niharikas931
over 7 years ago
This is the use case :-)
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Colton Beck
over 7 years ago
I will keep my user experience comments to myself :)
Have you tried substituting ri!r with a local variable declared in the with() statement?
What's likely happening is once you set ri!r the first time, it's persisting outside the scope of this child rule and not refreshing as you'd like it to.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
niharikas931
over 7 years ago
I reset the value of ri!r in submit button:
a!buttonWidgetSubmit(
label: "SUBMIT",
confirmMessage: ,
value: ri!q,
saveInto: {
a!save(
target: ri!p,
value: save!value
),
a!save(
target: ri!r,
true
)
},
disabled: ri!g = 0
),
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Colton Beck
over 7 years ago
If the validation fires, the value is not being saved to the variable. So in this case, ri!r is not being updated to true if the validationMessage condition evaluates to true.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
niharikas931
over 7 years ago
where exactly you want me to set ri!r?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sergiog
over 7 years ago
I hace the same problem, Do you find solution ?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
<