Important Update: Community URLs redirect issues are partially resolved. Learn More. .

cancel
Showing results for 
Search instead for 
Did you mean: 

custom code for to avoid the pipe(|) symbol in the text field using keypress event

ramss
Contributor II

how to create the keypress event custom code to avoid the | (pipe) symbol in a archer text field

6 REPLIES 6

DavidPetty
Archer Employee
Archer Employee

Ramkumar, is it a text field or text area field?

 Advisory Consultant

HI David,

This is Text field

David any possibilities to achieve this in custom code for text field David Petty 

ramss
Contributor II

David Petty‌ Hi david any suggestion for text field 

ramss
Contributor II

Ilya KhenDavid Petty‌ Any suggestion on this

I think David Petty presented nice example already:

Date Validation Custom Object 

 

It was for Date field, but you can do the same for Text Field by finding the proper element using DevTools, e.g:

	$('input[id*="f' + fldId + 'c"]').change(function(){
console.log("Text field changed");
});‍‍‍‍‍‍‍‍‍‍‍‍

 

And then use some regexp function or indexOf to seek for the pipe delimiter. You can also use other events, like keyup event instead of change, etc.