2014-10-17 105 views
1

由於某種原因,我在嘗試將FBLoginViewDelegate協議包含到我的ViewController接口時收到錯誤Cannot find protocol declaration for 'FBLoginViewDelegate'找不到'FBLoginViewDelegate'的協議聲明

我搜索了其他類似的問題,但大多數似乎與循環包含有關...我不認爲這是我的情況。

#import <UIKit/UIKit.h> 

@interface ViewController : UIViewController <UITextFieldDelegate, FBLoginViewDelegate> 

//Properties  
@property (weak, nonatomic) IBOutlet UITextField *txtPassword; 
@property (weak, nonatomic) IBOutlet UITextField *txtEmail; 
@property (weak, nonatomic) IBOutlet UILabel *lblResult; 

- (IBAction)loginClicked:(id)sender; 
- (IBAction)backgroundTap:(id)sender; 

@end 

我對iOS開發很陌生,任何幫助將不勝感激!

+0

添加#進口在您的.h文件中 – 2014-10-17 06:07:58

+0

修復了它!謝謝!如果你把它寫成答案,我會接受它。 – BlueBucket7 2014-10-18 05:12:48

回答

1

只是刪除,並添加添加FacbookSDK

使其

#import<FacbookSDK/FaceBookSDK.h> in your VC.h file or .pch file (the compiler takes the Facebook delegate in all VC's) 

終於乾淨並運行項目,它肯定工作

+0

有一個愉快的一天兄弟, – 2014-10-18 05:19:31

相關問題