Ah, found it, that info is in the attributeDict. - Koen.
On Sep 26, 2011, at 11:42 PM, Koen van der Drift wrote: > Thanks. The string I'm trying to match in an xml file that I'm parsing using > NSXMLElement. > > Here's part of the xml fie: > > <Item Name="one" Type="String">valueone</Item> > <Item Name="two" Type="String">valuetwo</Item> > <Item Name="three" Type="String">valuethree</Item> > > What I now found out is that the parser doesn't differentiate between the > three item elements, for all three the elementName is 'Item' in > didStartElement. Is there a way to do figure out what the 'Name' is, so I > can extract the three keys and values and store them in my model? > > Thanks again, > > - Koen. > > > > > > On Sep 26, 2011, at 8:35 PM, Conrad Shultz wrote: > >> -----BEGIN PGP SIGNED MESSAGE----- >> Hash: SHA1 >> >> On 9/26/11 5:26 PM, Koen van der Drift wrote: >>> How do I use isEqualToString with strings that contain a " ? >>> >>> The string I try to find is for instance: name= "foo" Type="bar" >>> >>> So: >>> >>> if ([myString isEqualToString: @"name= "foo" Type="bar"") >>> >>> Gives an error because there are too many " symbols. I looked >>> into replacing the " with ' by using >>> stringByReplacingOccurrencesOfString:withString: , but that gives >>> the same problem. >> >> Did you try escaping the inner quotes with backslashes? >> >> @"name= \"foo\" Type=\"bar\"" >> >> - -- >> Conrad Shultz >> >> Synthetiq Solutions >> www.synthetiqsolutions.com >> >> -----BEGIN PGP SIGNATURE----- >> Version: GnuPG v1.4.7 (Darwin) >> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ >> >> iD8DBQFOgRpLaOlrz5+0JdURAjE5AJ9Vbp1uINz+jQt6zFtYIqPkXVmSVACfUGoF >> 6U7QqtEotoTJ9RMTviBXK2s= >> =RGTT >> -----END PGP SIGNATURE----- > _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com