-1

I am following along with "How to Use iOS Charts API to Create Beautiful Charts in Swift" from Appcoda. I have downloaded their project template and then downloaded latest version of ios-charts. I have dragged the Charts.xcodeproj into my project and Embedded the Charts framework. Now when I try and build the project there are 26 errors and they are either "Expected ',' separator" or "Expected expression in list of expressions" errors, all of which are located in the ios-chart files. Has anyone else had this problem?

How can I fix it?

Screenshot of Xcode Errors

Stephen Coyle
  • 111
  • 1
  • 5
  • I have also created a new project and tried embedding iOS-charts again. Same errors appear. – Stephen Coyle Apr 12 '16 at 21:55
  • Is Xcode up to date? – catalandres Apr 12 '16 at 21:56
  • No, I'm using Xcode 7.2. I just seen an issue logged in the iso-charts [GitHub page](https://github.com/danielgindi/Charts/issues/900), which is the same issue I am having. They say to update to Xcode 7.3. Its downloading now. Will follow up later... – Stephen Coyle Apr 12 '16 at 22:04
  • Good luck. And patience. – catalandres Apr 12 '16 at 22:17
  • Updated Xcode, which also updated Swift. Still have one error in an iOS-charts file. The error is "Expected expression in list of expressions". Tried a new project then added the charts again same error. Tried cleaning then building again, same error. iOS-charts has a demo project and that builds? I'm adding the charts project as advised. – Stephen Coyle Apr 12 '16 at 23:12
  • @StephenCoyle try using pods. I was facing various issues when i tried the drag and drop method but pods worked perfectly for me. Checkout http://stackoverflow.com/questions/36305216/using-cocoapods-for-the-charts-framework-swift-2 if you need help with this. – Jess Murray Apr 13 '16 at 09:22

1 Answers1

0

I have now got this Appcoda example working. I'm not 100% sure what was wrong. But this morning I re-downloaded the starter project from Appcoda and re-downloaded the ios-charts zip file from GitHub.

Now what I done was copy the charts folder from the ios-charts zip file to the same directory as my Xcode project file. Opened my project in Xcode, then dragged the Charts.xcodeproj into the Project Navigator of my project. Give Xcode a minute or 2 to index files, then select my project file in Project Navigator and clicked + under Embedded Binaries then added the Charts.Framework.

I should also mention that I usually save and run all my Xcode projects from iCloud Drive, however this time I had the project in my Documents folder.

Stephen Coyle
  • 111
  • 1
  • 5