unrecognized-selector

iPhone - Unrecognized Selector, "may not respond to addTarget"

I'm working on a basic iPhone app to test some events, and I'm running into an error that I can't understand or find any answers for. I'm not using IB at all (aside from the MainWindow.xib it creates). Right now it's about as basic as it could be. mainAppDelegate.h #import <UIKit/UIKit.h> #import "mainViewController.h" @interface mai...

Confounding Cocoa problem — program hangs unless there’s an unrecognised method call.

Bear with me, this one is hard to explain. I hope some hero out there knows what’s going on here. Some history needed; One of my cocoa objects, “Ball” represents a small graphic. It only makes sense within a view. In some of the Ball’s methods, it asks the view to redraw. Most importantly, it asks the view to redraw whenever the Ball’s ...

Dynamic Button Problem: unrecognized selector sent to instance

I am dynamically creating buttons on iPhone app. UIButton *btn = [UIButton buttonWithType:UIButtonTypeRoundedRect]; [btn setTitle:atitle forState:UIControlStateNormal]; [btn addTarget:self action:@selector(buttonTouched:) forControlEvents:UIControlEventTouchUpInside]; // handle touch [buttons addObject:btn]; ---------- -(void) b...

EXC_BAD_ACCESS unrecognized selector sent to instance

//adds a button to scroll list -(void) addNode:(NSString *) atitle{ UIButton *btn = [UIButton buttonWithType:UIButtonTypeRoundedRect]; [btn setTitle:atitle forState:UIControlStateNormal]; [btn addTarget:self action:@selector(buttonTouched:) forControlEvents:UIControlEventTouchUpInside]; // handle touch [bu...

Universal app iPad version IBAction throwing NSInvalidArgumentException unrecognized selector

For some reason I cannot figure out I have an IBAction code wired up to fire on the touchupinside for a UIButton on a view using Interface Builder. Simple stuff right?? Well it works fine in my iphone version but for some reason I keep getting the following error when I click on the button in the iPad even though I have it wired up pro...

How can I isolate third-parties' C/C++/ObjC libraries' symbols from each other?

I have a project that needs to incorporate two third-party libraries, libA and libB. I have little, if any, influence over the third-party libraries. The problem being is that both libA and libB include different versions of a common library, ASIHTTPRequest. As a result, I'm getting errors like: -[ASIFormDataRequest setNumberOfTimesToRe...

Core Data: NSManagedObjectContext save crashing with unrecognized selector

I'm trying to add Core Data to an existing application, which isn't easy considering that all the documentation and every tutorial starts out with creating an app that uses core data from the start. So I'm trying to convert an existing model class to be a core data entity. Here's what I did: Add the core data framework. Add an xcdatamo...

RemoveFromSuperview sending unrecognized selector to view controller

I have a view controller called GobanVC. It's adding a subview to do a magnification effect. That works fine, but when I call removeSuperview to get rid of it, I get an unrecognized selector error: 2010-08-26 10:10:04.014 GoGrinder[4257:207] -[GobanVC _invalidateSubviewCache]: unrecognized selector sent to instance 0x5a2f540 2010-08-2...

how convert NSDictionary element to NSData (dataUsingEncoding cause crash)

Hi all, i try to convert NSDictionary element to a NSData element: ... while ((key = [enumerator nextObject])) { NSString *temp = [dictionary objectForKey:key]; if ([key isEqualToString:@"results"]) { //Crash HERE! -------------------------->>>> NSData *myData2 = [temp dataUsingE...

Unrecognized Selector Sent to Instance [NSCFString subarrayWithRange:]

I have the following code which is producing this error. I cannot understand why the subarrayWithRange message is being sent to a string? When it is clearly an array? static const int kItemsPerView = 20; NSRange rangeForView = NSMakeRange( page * kItemsPerView, kItemsPerView ); NSMutableArray *temp = [[APP_DELEGATE keysArray] mutableCo...