如何在viewcontroller中,等数据请求成功后,再加载xib
1个回答
展开全部
接下来得建立CustomViewViewController.xib中的view与CustomView.xib的关联了,即将Custom.xib动态加载,然后将该view做为CustomViewViewController的view的subview,放置于正中显示(设置CustomView的中心点为整屏正中央),具体代码如下:
- (void)viewDidLoad
{
[superviewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
NSArray *nib = [[NSBundlemainBundle]loadNibNamed:@"CustomView"owner:selfoptions:nil];
- (void)viewDidLoad
{
[superviewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
NSArray *nib = [[NSBundlemainBundle]loadNibNamed:@"CustomView"owner:selfoptions:nil];
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询