objective c - Making first iOS App work -
i trying learn building apps using ios. using xcode 6.4, , the tutorial following seems accept using fun , override, when try it, brings errors. connecting protected page registration page this.
#import "viewcontroller.h" @interface viewcontroller () @end @implementation viewcontroller - (void)viewdidload { [super viewdidload]; // additional setup after loading view, typically nib. } - (void)didreceivememorywarning { [super didreceivememorywarning]; // dispose of resources can recreated. - (void)viewdidappear(animated: bool) { [self.performseguewithidentifier("loginview", sender: self)]; } } @end
can please me point out error , solution?
welcome so. typically isn't general debugging service might foot up...
- in objective-c methods can't declared inside other methods. can in swift
- swift code can't smooshed alongside objective-c code.
- case important in swift , obj-c
performseguewithidentifier
not sameperformseguewithidentifier
so correct version of trying is...
@interface viewcontroller () @end @implementation viewcontroller - (void)viewdidload { [super viewdidload]; // additional setup after loading view, typically nib. } - (void)didreceivememorywarning { [super didreceivememorywarning]; // dispose of resources can recreated. } - (void)viewdidappear:(bool)animated { [self performseguewithidentifier:@"loginview" sender:self]; } @end
have fun , enjoy ios dev.
Comments
Post a Comment