I added the Parse SDK in my project and everything was well. However when I quit Xcode and opened the project I got these errors:
Parse/Parse.h file not found
@Tuyen answer help me solve this problem. However I'd like to make it more clear.
In Build Setting > Framework Search Path
, add a new path $(PROJECT_DIR)
and set recursive.
I put all 3rd party framework under project directory /framework, so this setting will surely find the framework file.
Not sure if it works. Never had this problem like you before. Anyway check this one.
Hope it helps.
I have the same problem. Here is my solution.
After these steps, this problem goes away.
create new parse app download parse sdk for ios
create new project - master detail go to build settings under search paths >> framework search paths >> 1) debug - add $(PROJECT_DIR)/** 2) release - add $(PROJECT_DIR)/**
go to general tab
under Linked frameworks and libraries,
Add the following frameworks from parse SDK
Parse.framework
ParseCrashReporting.framework
Bolts.framework
ParseUI.framework
Also add the below frameworks
AudioToolbox.framework
SystemConfiguration.framework
Add the below frameworks using "Add framewors popup" -->> Add other -->> ctrl+shift+g --> enter /usr/lib/ -->>
choose the following
1) libz.1.dylib
2) libsqlite3.dylib
create new file -->> chose Objective-C type -->>create. Xcode will ask you whether you want to create a bridging header? select yes. it create 2 files. one is .m file and one is .h file go to .h file, add the following line #import
Open up the AppDelegate.swift file, uncomment and edit the setApplicationId line in the application:didFinishLaunchingWithOptions function with your keys: Example: Parse.setApplicationId("sJjEQei2m15RD9MJiZjVtygI1o6wQ23TxhdIllUo", clientKey: "IZDfhmPiO2b01yEacRBAStyKAznXrguFku78pWO3")
Test the SDK
First make sure to include our SDK imports at the top of your ViewController.swift file:
import Parse
Then copy and paste this code into your app, for example in the viewDidLoad function of ViewController.swift:
let testObject = PFObject(className: "TestObject")
testObject["foo"] = "bar"
testObject.saveInBackgroundWithBlock { (success: Bool, error: NSError?) -> Void in
print("Object has been saved.")
}
Run your app. A new object of class TestObject will be sent to the Parse Cloud and saved. When you're ready, click the button below to test if your data was sent.