PDA

View Full Version : Error-[UIViewController NextView:]: unrecognized selector sent to instance




pitchai.pazhani
Jan 18, 2011, 03:50 AM
Hi,

I am developing an Universal Application. I have tabcontroller in my application and each tab displaying different views.

Now the problem is, when I have a button in any views, it displays the above error.
________________________________________________________

@interface ScreenFourViewController : UIViewController {

}
-(IBAction)NextView:(id)sender;

@end

_______________________________________________________


@implementation ScreenFourViewController

-(IBAction)NextView:(id)sender
{
NSLog(@"Start button pressed"); }
_______________________________________________________

What am I doing wrong? Please help me.

Also, I want to change the views of a particular tab, when I click the next button from the current view.



cnstoll
Jan 18, 2011, 09:51 AM
Looks to me like you're trying to send "nextView" to UIViewController.... You should probably be sending it to an instance of ScreenFourViewController. Or, if you're trying to call NextView from within ScreenFourViewController...send NextView to self.