On Oct 26, 2008, at 2:59 PM, john fogg wrote:

When I'm inside "secondSubObject" how can I alter a variable in
"secondMainObject"?

Use accessors. In secondSubObject, create an @property(assign) SecondMainObject *secondMainObject; so that you can call methods in secondMainObjct from secondSubObject.

Note that it's important that you assign instead of retain in this instance, or else you'll create a retention loop memory leak unless you're using GC.

And how can I alter a variable in "firstMainObject"?


Again, use accessors so that objects can communicate with other objects.

Nick Zitzmann
<http://www.chronosnet.com/>

_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to