Skip to main content
Nintex Community Menu Bar

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

  • July 17, 2018
  • 6 replies
  • 30 views

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
  • July 18, 2018

use validation rules to check whether inputs meet your requirements.

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


Forum|alt.badge.img+2
  • Author
  • July 27, 2018

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.


EuanGamble
Nintex Employee
Forum|alt.badge.img+13
  • Nintex Employee
  • October 29, 2018

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


Forum|alt.badge.img+2
  • June 12, 2019
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! :)

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. 


Forum|alt.badge.img+2
  • June 19, 2019
Hi FabioLiberatore... About to upgrade to the latest greatest, but current on Version: 4.3.1.0...