Question

1
Replies
2322
Views
Close popover
Siripuram Mahesh (MAHI252385)
Infosys
Consultant
Infosys
IN
MAHI252385 Member since 2010 21 posts
Infosys
Posted: October 1, 2018
Last activity: February 17, 2021
Closed
Solved

Validate Specific character in String

HI,

I have a requirement to validate clipboard properties having specific character.

String pattern – ^[a-zA-Z 0-9 \- \\ _ /]{0,50}$

If the string have any other character, i have to reject it.

i have tried function rule to validate the string value but still unable to get proper format.

Please help here.

Java Code written in Function rule:

if (strInput .equals("")){
return true;
}
String validURLstr = ("–^[a-zA-Z0-9 \\_/]$");
return java.util.regex.Pattern.matches(validURLstr,strInput);

Thanks in Advance.

***Updated by moderator: Lochan to update platform capability***

Case Management User Experience
Moderation Team has archived post,
Close popover This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.