-1

I'm doing a tab button on my navigation bar of my (FirstViewController),when i press button it should pop me the view controller(FlipsideViewController).i had this linker error message

Undefined symbols for architecture i386:

_OBJC_CLASS_$_FlipsideViewController", referenced from: objc-class-ref in FirstViewController.o ld: symbol(s) not found for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation)

this is my code in

#pragma mark - Flipside View 
- (void)flipsideViewControllerDidFinish:(FlipsideViewController *)controller 
{ 
    [self dismissModalViewControllerAnimated:YES]; 
} 
- (IBAction)showInfo:(id)sender 
{ 
    FlipsideViewController *controller = [[FlipsideViewController alloc] initWithNibName:@"FlipsideViewController" bundle:nil]; 
    controller.delegate = self; 
    controller.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal; 
    [self presentModalViewController:controller animated:YES]; 
}
Till
  • 27,559
  • 13
  • 88
  • 122
prediv
  • 1
  • 2
  • #pragma mark - Flipside View - (void)flipsideViewControllerDidFinish:(FlipsideViewController *)controller { [self dismissModalViewControllerAnimated:YES]; } - (IBAction)showInfo:(id)sender { FlipsideViewController *controller = [[FlipsideViewController alloc] initWithNibName:@"FlipsideViewController" bundle:nil]; controller.delegate = self; controller.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal; [self presentModalViewController:controller animated:YES]; } – prediv Oct 01 '12 at 09:51
  • The problem is not in FlipsideViewController but rather in the way that you include it into the project. – pro_metedor Oct 01 '12 at 10:01

3 Answers3

0

You are missing FlipsideViewController file compiled or linked into code. Check: Project->Build Phases->Compile Sources if you have there FlipsideViewController file.

enter image description here

Also check if its included into project.

pro_metedor
  • 1,176
  • 10
  • 17
  • thanks i just add the file in my compile sources.but i had this error – prediv Oct 01 '12 at 10:06
  • @synthesize delegate = _delegate;...........the current deployment target does not support automated_weak references – prediv Oct 01 '12 at 10:07
  • Does your target is iOS verson below 5.0 ? If yes, disable ARC in build settings project>Build Settings->Objective-C Automatic ReferenceCounting set NO and contnue development with retain/release/autorelease memory management. – pro_metedor Oct 01 '12 at 10:10
0

The linker warning has nothing to do with the code. It's just that the compiler couldn't find the class FirstViewController which you'll have to add to compile sources:

enter image description here

tipycalFlow
  • 7,594
  • 4
  • 34
  • 45
  • thanks i just add the file in my compile sources.but i had this error – @synthesize delegate = _delegate;...........the current deployment target does not support automated_weak references – prediv Oct 01 '12 at 10:11
  • It seems you have ARC turned on. Check [this SO question](http://stackoverflow.com/questions/6893038/how-do-i-replace-weak-references-when-using-arc-and-targeting-ios-4-0) – tipycalFlow Oct 01 '12 at 10:15
0

Your FlipsideViewController implementation is missing from the files to be linked.

Check your project settings by tapping on the Top-Node within the Project Navigator -> Build Phases -> Compile Sources.

enter image description here

FlipsideViewController.m must be listed. If it is not, use the + Symbol on the bottom to add it.

Till
  • 27,559
  • 13
  • 88
  • 122