Even though I wrote the original, rather messy, version of jList over five years ago I’ve never had the need for a listContains function i.e. one that searches a list looking for an item which at least partially matches a string. Until now, that is.
Determines the index of the first list element that contains a specified substring.. The search is case-sensitive.
Determines the index of the first list element that contains a specified substring. The search is not case-sensitive.
These functions look at each individual element of a list for a specific value. Where the value being searched for is wholly or partially contained within an element then the position of that element in the list is returned. Where no match is found, zero is returned.
would return 4 even though the value itself is not in the list.
All documentation is updated so full details of the new functionality is on the jList GitHub page.
jList 1.5.o can be downloaded for free from GitHub.