I am using following Regex:
NSString *pattern = @"KEYIDSTREQ(?<SpeakerID>.*?)#MEMNAMESTREQ(?<SpeakerName>.*?)#MEMSPEAKNUMSTREQ(?<SpeakerNumberToSpeak>.*?)#MEMTRSTREQ(?<Time>.*?)#REQLED(ON|OF)#TALKLED(ON|OF)#SUMLED(ON|OF)#STOPLED(ON|OF)LT(?<HexNo>.*?)";
NSError *error = nil;
NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:pattern options:NSRegularExpressionCaseInsensitive error:&error];
if(!error) {
// My code...
}
It is working correctly with iOS 9.0+ but when I run this code with iOS 8.1+ then I am getting following error message:
Error Domain=NSCocoaErrorDomain
Code=2048 "The operation couldn’t be completed. (Cocoa error 2048.)"
UserInfo=0x16e19c60 {NSInvalidValue=KEYIDSTREQ(?<SpeakerID>.*?)#MEMNAMESTREQ(?<SpeakerName>.*?)#MEMSPEAKNUMSTREQ(?<SpeakerNumberToSpeak>.*?)#MEMTRSTREQ(?<Time>.*?)#REQLED(ON|OF)#TALKLED(ON|OF)#SUMLED(ON|OF)#STOPLED(ON|OF)LT(?<HexNo>.*?)}
What I am missing in that ? Any clue ?