I know user info is used to pass a parameter, but how do I pass more than one of these?
I’m guessing I have to use an object, but as I am fairly new to objective-c I don’t really know if this is right and how to go about it?
Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Create a wrapper object, an
NSArrayorNSDictionarywith the multiple objects you need to pass and pass that wrapper object inuserInfo. On the receiver retrieve the objects from the wrapper object.Example code using a NSDictionary for the wrapper:
Calling code:
Receiving timer code: