Activity Forums Salesforce® Discussions How to look for a string from a List of strings?

  • Ravi

    Member
    April 28, 2016 at 1:39 PM

    Hi Gourav,

    You can do it without iterating list  by using regex:

    if (myList.toString().matches(".*\\bA\\b.*"))

    You have to make regex of search string.

  • Gourav

    Member
    April 28, 2016 at 2:16 PM

    @Piyush

    Can you elaborate it because I didn't find anything there!

  • Gourav

    Member
    April 28, 2016 at 2:17 PM

    @Ravi

    Please provide some example!

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos