• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSScanner Unresolved Infinite loop. Help.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSScanner Unresolved Infinite loop. Help.


  • Subject: NSScanner Unresolved Infinite loop. Help.
  • From: email@hidden
  • Date: Sun, 9 Jun 2002 20:30:25 -0400

Hi,
I'm porting my app from Rb to cocoa.
I'm writing an app that fetches XML and displays specific ...
I use NSScanner to parse stuff in the XML file.

What i need it the strings between the <title> markers.

What I did is.

<CODE>
NSLog(@"Read response.");
// Scan the goodies out of the whole file.
RDFScanner = [NSScanner scannerWithString:responseString];
while ([RDFScanner isAtEnd] ==
NO) { //
STOPS EXECUTING HERE.
if ([RDFScanner scanString:@"<title>" intoString:NULL] &&
[RDFScanner scanUpToString: @"</title>"
intoString:&titleData] ){
[headlinesArray addObject:titleData];
NSLog(@"Got Headline #%d",[headlinesArray count]);
}
}
</CODE>

Just email me if you want the whole PBPROJ.
I really need help :D



-Jean-Olivier Lancttt-David
--------------------------------------------------------------------
Creator of PodNews, a popular utility for your iPod
http://ambush.avara.net/podnews
--------------------------------------------------------------------
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: Where does one add the $CLASSPATH environment variable?
  • Next by Date: Re: Objective-C Specification
  • Previous by thread: Re: Where does one add the $CLASSPATH environment variable?
  • Next by thread: [Q] Framework question
  • Index(es):
    • Date
    • Thread