You need to sign in to do that
Don't have an account?

How to check whether the string contains any quotation marks or not.
Hi All,
I have List of String Values like [abc, “abcd” ,‘abcde’].
Now i want to check all the string values and find which string contains single quotes(') and which one contains double quotes using apex.
Can any one help me how to solve this problem......
Thanks,
Murali
I have List of String Values like [abc, “abcd” ,‘abcde’].
Now i want to check all the string values and find which string contains single quotes(') and which one contains double quotes using apex.
Can any one help me how to solve this problem......
Thanks,
Murali
String test='';
test.contains('\'');
Hope this helps !!
If
String test='\'abc\'';
then only
test.contains('\''); This statement will work..
But in my case the string is like 'abc'.
This time Contains method is not working.
https://developer.salesforce.com/forums/ForumsMain?id=906F00000008oE7IAI
http://www.salesforce.com/us/developer/docs/pages/Content/pages_variables_functions.htm