Get Updates By E-mail 

Article Written By:
Johann Dowa

Open Source Objective-C Library For Easily Parsing/Writing CSV Files

  •  
  •  
  •  
  •  
  •  

Properly parsing CSV (comma separated value) files can be difficult due to the memory limitations on iOS devices, and the need to handle different encoding formats.

Here’s a library from Dave DeLong called CHCSVParser that can parse and create CSV files properly on iOS devices.

CHCSVParser avoids memory issues by only parsing a section of the file at a time, and lets you easily deal with different delimiters, and encoding formats.  You can supply the file to be parsed or provide an NSString or NSStream containing the CSV information.

You can also save data to a CSV format with your choice of delimiter.

You can download CHCSVParser on Github here.

If you’re looking to download and parse a remote CSV file you may want to look at this AFNetworking extension that uses CHCSVParser to perform the CSV parsing.

If you’re having issues with parsing/saving CSV data this library makes it easy.


  •  
  •  
  •  
  •  
  •  

Submit A Resource

Have you created a useful tutorial, library or tool for iOS development that you would like to get in front of our 300,000+ monthly page views from iOS developers?

You can submit the url here.

The resources we feel will appeal to our readers the most will be posted on the front page.

Comments