Skip to main content
Nintex Community Menu Bar

how do i change the border of list lookup to red to show incorrect input?

  • Jul 17, 2018 7:18 AM UTC
  • 6 replies
  • 41 views
  • Translate All

Forum|alt.badge.img+2

if(fromShortcode.val() == toShortcode.val()){
 alert('same values entered in both the field!');
 NWF$(shortCode).addClass('border-red');
 }
 else
     {
      NWF$(shortCode).removeClass("red-border");
     }
  });
});

this is te code I have written where if the 'if' condition gets true then the list lookup field(shortCode) is to be set to red border or it should remain black itself

6 replies

Forum|alt.badge.img+14
  • Scholar
  • Jul 18, 2018 12:45 PM UTC

use validation rules to check whether inputs meet your requirements.

if validation doesn't pass through respective controls will be automatically highlighted.

Translate

Forum|alt.badge.img+2
  • Author
  • Jul 27, 2018 11:19 AM UTC

Yes thank you for the reply, the validation rules work when the form gets submitted.

while solving it I tried doing that in real time (i.e before submitting the form) using JavaScript and CSS and it worked for me.

I'm sharing the code as it can be helpful to someone.

NWF$(".border").css({"border-color": "#FF0000",
             "border-width":"3px",
             "border-style":"solid"});

the above code goes in the custom JavaScript field

And in the 'control CSS class' of the field u want to highlight(which you will get in the formatting field in settings)u have to name it border.

Translate

EuanGamble
Nintex Employee
Forum|alt.badge.img+13
  • Nintex Employee
  • Oct 29, 2018 5:36 AM UTC

Hi all,

 

Our UX team are doing some research into our style builder for Universal Forms. We would appreciate your feedback on your current experience in styling your forms in any platform.

 

If you would like to provide feedback, please fill out the survey at Applying styles in Nintex Forms 

 

Thanks,

Euan

Translate

Forum|alt.badge.img+2
  • Jun 12, 2019 7:31 PM UTC
Ever have to change the color of the highlighted field on a form for color blind end-users? I'm looking for help there... I've changed the color or error messages easily, but haven't found the right code for changing the border color on highlight whenever a validation rule is triggered. Help! thanks! :)
Translate

Forum|alt.badge.img+1

Hi @cbennett1 this is Fab and I work as a User Experience designer for Nintex Forms and Mobile. I am currently working on a new experience for form styling that we will introduce across Universal Forms. Can I ask as to what version of Nintex forms you are currently designing in? 

Hope to hear from you soon and Kind Regards. 

Fab. 

Translate

Forum|alt.badge.img+2
  • Jun 19, 2019 7:38 PM UTC
Hi FabioLiberatore... About to upgrade to the latest greatest, but current on Version: 4.3.1.0...
Translate