2013-03-26 14 views
0

我有一個名爲StreamController的UIViewController。它有一個帶有UITableViewController的XIB。從MyClass繼承:UIViewController導致錯誤'無法找到接口聲明'

我想創建另一個這個StreamController略有不同的視圖,但使用原來提供的相同的代碼,所以我創建了另一個名爲Stream2Controller的控制器。 Stream2Controller繼承自StreamController並擁有自己的XIB文件。

我的意圖是將Stream2Controller XIB文件中的引用出口指向StreamController.h文件。我敢肯定,我已經成功地在這過去,但出於某種原因,我得到這個錯誤:

Cannot find interface declaration for StreamViewController, superclass of Stream2Controller; did you mean SomeOtherController?

此錯誤是在Stream2Controller.h

UPDATE發生的事情:下面是一些源

`StreamController.h」

@interface StreamViewController : UIViewController 

'海峽eam2Controller.h'

#import "StreamViewController.h" 

@interface Stream2Controller : StreamViewController 

建議?

+0

檢查StreamViewController.h是否已添加到您的目標? – nkongara 2013-03-26 17:45:00

+0

StreamViewController被添加到我的目標。 – bugfixr 2013-03-26 20:54:51

回答

2

看起來像我有一個遞歸包括我的項目中導致此錯誤的其他地方。

雖然不是非常直觀的錯誤信息。 :)

+0

+1您的解決方案是唯一幫助我的東西!好棒!! :d – 4FunAndProfit 2014-11-15 00:11:12

相關問題