How to set background image of a view?

后端 未结 7 1271
梦如初夏
梦如初夏 2020-12-04 16:35

I am a beginner at Obj-C/Cocoa Touch/iPhone OS.

I wish to have a background for my app with different images everytime the the view is called.

Say I have 10

7条回答
  •  清歌不尽
    2020-12-04 17:40

    use this

    self.view.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"Default"]];
    

提交回复
热议问题