Looking for a JavaEE Architect or Potential Tech Co-Founder?
Please don't hesitate to contact me.

XCode How to check if a string contains another string

 NSString *string = @"how to check if a string contains another string";

 if ([string rangeOfString:@"how"].location == NSNotFound) 
 {
     NSLog(@"Not found");
 } 
 else 
 {
     NSLog(@"Found");
 }
XCode How to check if a string contains another string XCode How to check if a string contains another string Reviewed by Edmond Legaspi on Friday, August 01, 2014 Rating: 5

No comments:

Powered by Blogger.