XML Parsing issue in Xcode?

倾然丶 夕夏残阳落幕 提交于 2019-12-04 20:52:39

The error is in your parser. Please revise the logic. You are not using your object item when filling your table view array. Also, you are not catching the text in between the XML elements and are not assigning them to the appropriate variables.

Note the following:

  • When you enter an element, keep track of which element you are in currently
  • When you find characters you have to fill the appropriate attribute variable according to which element you are in
  • When you finish the event element, you should add your item with all its filled in keys into your data array.

You need to know how to use array. You are allocating one array stories. But then not using. Please Check your didEndElement method.

Make one class of Event, create .h and .m file and then create properties of your all element and then add whole object of Event class into an array. That array you can in appHandler or Single ton class.

Check this thing. May it help you.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!