justinmind-logo
 
Upvote 1

input field is empty or full event

Answered Victor Conesa 8 years ago

Hello,


I have an input field and I have a text, which is my button in this case.


So, the scenario is that whenever, the input field is filled out (with numbers, texts and etc.) then the button (text) turns to red, in order to show it is activated.


However, when the input is not filled or not clicked by user, the text is light grey and inactivate. So, even when one tries to click on the text with out filling out the input field, the text color doesn't change.


Now, I want to simulate this action and I don't know how I can set an event which describe, input is filled, input is not filled (or clicked). I played around a little bit with giving them some value (like when it is clicked is 1, when not is 2) but it doesn't work for me.


Thanks for the help.

Best Answer
photo

Hi there,


You can create this event by:


1) Creating an 'on focus out' event for the input field with the output 'Change style' for the button


2) Create the 'When' condition to be: 'When (input field), Not=, (empty text field, or nothing written)'


Let me know how this works for you.


Best,


Danielle

Replies (1)
photo
1

Hi there,


You can create this event by:


1) Creating an 'on focus out' event for the input field with the output 'Change style' for the button


2) Create the 'When' condition to be: 'When (input field), Not=, (empty text field, or nothing written)'


Let me know how this works for you.


Best,


Danielle

Leave a Comment
 
Attach a file