17
Views
3
Comments
Solved
[Password Validate Reactive] Password Validate Using button
password-validate-reactive
Reactive icon
Forge asset by Mobarak Dimalotang
Application Type
Reactive
Service Studio Version
11.55.21 (Build 64159)
Platform Version
11.35.0 (Build 45040)

Good day!

I'm using the Password Validator Reactive component from Forge in my app. When I type in the input, it validates automatically (on change).

However, I want the password to be validated only when I click a button, not while typing.

The problem is:

  • The Password Validator has an event handler.

  • My custom button does not have an event that triggers the validator.

Is there a simple way to make the button trigger the password validation manually?

Thank you!


PasswordValidatorDemoButton.oml
2020-05-07 18-53-00
Rui Barradas
 
MVP
Solution

Hello jesu,

Hope you're doing well.

After installing this Forge component, I verified that there is no Web Block called WB_PasswordValidator.

I think you pretended to mention this one instead: Password Validator Reactive. The name is quite similar, but it is not the same.


Anyway after exploring the component, the main reason why it is validating automatically, is because of this EventListener in the OnReady event of the Block:

This keyup event is fired when a key is released.


In order to do what you pretend, basically you'll need to pass the logic from the Block to the Screen. Therefore you will not need the WB_PasswordValidator Block at all.


You just need to adapt your CheckItOnClick client action in order to include the necessary logic:

You'll also need to include the Password_BuildRegexPattern client action in your module.


Last but not least, you need to adapt your IsValid if statement with the correct condition:


Please refer to the attached OML file that contemplates these changes.

Hope that this helps you!


Kind regards,

Rui Barradas

PasswordValidatorDemoButton.oml
UserImage.jpg
jesu verso

Thank you so much for replying and sir  sorry for my confusion and might check this, thank you sir

UserImage.jpg
jesu verso

and may i ask sir if the value is fixed? that i will include already the details in the left? i will input the true false and min and max inside the backend

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.