I want to create (or update) a PFObject with an array of strings, so that each element of the array can be editable. For example, I want the array to contain the words "Hello" and "World" so that if I wanted, I could access and rewrite the first element of the array to instead say "Goodbye".
Here's what I have:
PFObject *newStringArray = [PFObject objectWithClassName:@"myFirstClass"];
[newStringArray setObject:@"Hello" forKey:@"arrayOfStrings"];
[newStringArray saveInBackground];
The above code doesn't give me any errors, and it doesn't save to Parse. I've also tried using:
[newStringArray addObjectsFromArray:@[@"Hello", @"World"] forKey:@"arrayOfStrings"];
But this code returns the error "Error: invalid type for key arrayOfStrings, expected string, but got array"
Please let me know if you have any suggestions for how I can fix the array problem, or if I should be trying a different method of collecting/accessing strings within a wall of text. Thanks