Search code examples
objective-ccocoansstringstringwithformat

save substring from a string in Objective-C


i am having a string like: funcname("data"),comes from upstairs.now i want to save the funcname, data in two NSString variables i.e i need to find the string present in between "" and the string before'('.


Solution

  • There's a very useful class NSScanner that will help you to parse different tokens easily.