site_archiver@lists.apple.com Delivered-To: cocoa-dev@lists.apple.com On Sep 30, 2005, at 10:07 AM, Jim Correia wrote: On Sep 30, 2005, at 9:19 AM, Aaron Wallis wrote: You don't "call a selector," you send a message. SEL selector = NSSelectorFromString(@"aSelector"); sherm-- Cocoa programming in Perl: http://camelbones.sourceforge.net Hire me! My resume: http://www.dot-app.org _______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/site_archiver%40lists.apple... I was wondering how I would go about getting cocoa to call a selector defined in a string? [object performSelector: selector withObject: nil]; In addition, if the method in question takes more than two arguments, or takes and/or returns a non-object type, there's NSInvocation. It's more complex, but it's capable of handling any number and type of arguments, and any type of return value. This email sent to site_archiver@lists.apple.com