开发者

Circular Dependency of Navigation Control in iPhone

In my view this is one of the strangest problem i have ever come across in iPhone app development.

Let me explain the scenario , i have main screen 'A' on which i have a Button 开发者_运维问答that directs me to another Screen say 'B'. Now on Screen 'B' i have a feature in which user can send a mail to his friend for promotion purpose e.g a user wishes to tell a frnd about this app so i used MFMailComposeViewController and a view is generated where the user types the address and click send ( subject and body of mail is automatically generated ). After sending the mail a new view opens say screen 'C' and here i want to give the user the options . 1. Go to Screen 'A' ( which is main screen of the app ) 2. Go back to Screen 'B' ( from where the user requested to send a mail to his frnd ).

Now the strange part i cannot declare the variables ( Screen 'A' and 'B' ) of both these files here at in header file of screen 'C' . Even when i declare the header file at the top it generates an error. The variables can be easily be declared and used for other screens but not for these 2 screens. Can anybody please explain wats the problem.? this the text of the error "/Users/admin/Documents/AppName/Classes/A.h:42: error: expected specifier-qualifier-list before 'B'" Thanks Guys !

Taimur


you can normally use @class to resolve circular dependencies if that is what is is, but by the sounds of the error, it could just be a stray semi-colon or other syntax error in a header.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜