开发者

Unable to change UITableViewController color background

TitlesViewController : UITableViewController

I have the above code on iPhone development. This is associated to a xib (or nib开发者_如何转开发) file. In this property file I change its background color. The problem is it does not reflect my new background color. Should I be manually loading the xib file to reflect it to my TitlesViewController?


Some quick points:

You don't change the colour of a view controller, you change the colour of a view controller's view.

A xib is an XML file that tells Xcode how to create a matching nib. Neither are property files (you are likely mixing them up with plist files).

You should be able to set the background colour for just about any UIView (or subclass thereof) in your xib file. So the question is, how were you setting it the colour, what were you expecting to happen, and what did you get?


viewcontroller.view.backgroundColor=color;

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜