Reputation: 584
I have a swift iPhone application that stored data the user entered into various variables, structs, objects, etc. I would like to write that data to a file. I have a template that will be stored in my project files on the phone. So what the app is supposed to do is take that template, save it as another file, and add the data the user entered from the app to the file.
My question is, I already have it set up so the user enters the data into the app using swift. Is it possible to integrate C so that the C file takes the information from Swift file and writes that data to a file? If so, can you point me to a direction? (tutorial if possible..)
I did some research on it and sadly the only thing I could find is obj-c stuff with view controllers and how to integrate obj-c with swift.
Thank you!
Upvotes: 0
Views: 83
Reputation: 625
Yes! You can mix them. This is a link to download e-book "Using Swift with Cocoa and Objective-C" It's FREE.
https://itunes.apple.com/it/book/using-swift-cocoa-objective/id888894773?mt=11
Upvotes: 1