NSXML Parser not engaging?


I’m similarly looking at my own challenge from Chap 25, have a question. Can anyone explain why an NSXMLParser would not engage when called, or start doing its job?

In a nutshell, i entered the code from Chap 25 “as is” using XCode 4.2 / iOS 5 conventions … like ARC … no need for releases :slight_smile: yay, go apple! … making only such changes as Xcode demanded or i understood to be necessary (ie. close to nil)… and using a Storyboard. Simple. But for some reason nothing is being parsed :frowning: … or the parser is never finding the element in self.xmlData. I’m stumped. The RSS feed is coming in fine prints fine, start to finish … but the parser does not appear to be engaging.

On page 419: “Build and run … you should see a log message that the channel was created.” (not here)
On page 421: “Build and run … you should see log statements with valid values …” (mine are Null)

everything runs fine up till that point … but values are null :frowning:

Any suggestions?


ok, iOS 5 so … moved -(void)fetchEntries method call to viewDidLoad … noticed NSXMLParser was still giving no sign of anything, nothing … then i accidently ran the method twice :slight_smile: GoSEAN.org … bam the xmlparser error method came to life!! So, assuming NSXMLParser is running fine :slight_smile: go apple … and that BNR RSS feed is complete (it is) … why isn’t parser:didStartElement recognizing the initial elementName = “channel” and shouting “hey everybody, i found an element”?


Can you post your code, please?


I know that there is a new book out, that would likely fix my problem, but I have this one already on my iPad and more than that, I want to figure out why it is not functioning, so I can better learn iOS.

I have the same problem. The NSLog to print the channel info puts out null for the 3 channel variables.

I’m not sure why though.

Did you find a solution to this?