-1
我有一個UIView
子類。我無法在這個UIView
類中創建另一個View Controller的實例,這樣我可以訪問此View Controller中我的UIView
子類中設置的變量?任何人都可以指導我這個無法創建視圖控制器的實例
#import <UIKit/UIKit.h>
#import "DirectoryFormViewController.h"
@class NIDropDown;
@protocol NIDropDownDelegate
- (void) niDropDownDelegateMethod: (NIDropDown *) sender;
@end
@interface NIDropDown : UIView <UITableViewDelegate, UITableViewDataSource>
{
NSString *animationDirection;
UIImageView *imgView;
DirectoryFormViewController *dict; // i am not able to create this
}
@property (nonatomic, retain) id <NIDropDownDelegate> delegate;
@property (nonatomic, retain) NSString *animationDirection;
-(void)hideDropDown:(UIButton *)b;
- (id)showDropDown:(UIButton *)b:(CGFloat *)height:(NSArray *)arr:(NSArray *)imgArr: (NSString *)direction;
@property(nonatomic)int countryID;
@end
我DirectoyFormViewController:
#import <UIKit/UIKit.h>
#import "NIDropDown.h"
@interface DirectoryFormViewController : UIViewController<DropDownListDelegate,CLLocationManagerDelegate,UISearchBarDelegate,UITextFieldDelegate,NIDropDownDelegate>
@property(nonatomic)NSMutableDictionary *countryName;
@property(nonatomic,copy)NSMutableDictionary *sortName;
@property(nonatomic,copy)NSMutableDictionary *resultName;
@end
我想設置國家名稱,sortName和resultName在我NIDropDown
感謝
你做了什麼?分享您的代碼 – Retro
任何錯誤或警告 –
未知類型名稱爲'DirectoryFormViewController' – Vishnu