0

I have question that how could I set the ImageView image object as a background in my iPhone I use sdk 4.2 and in iPhone 4 its possible to set the backgound image in iPhone... So my case is that if some one likes the picture then they should give the UIAlertView to set as a background... OK & Cancel option in ok option its automatically set the image as a background.

My object are as follow:

UIImageView *imgViewObj = [[UIImageView alloc]init];
[imgView setImage:[UIImage imageWithName:@"sampleImage.png"]];

I have to set this imgView obj as a background image...

Cajunluke
  • 3,103
  • 28
  • 28
Appz Venture
  • 939
  • 1
  • 13
  • 28

2 Answers2

3

No, you cannot programatically set a user's wallpaper in iOS (yet anyway). You can probably do it on JB devices though, but that won't get you on the Apple appstore.

Cajunluke
  • 3,103
  • 28
  • 28
Daniel
  • 22,363
  • 9
  • 64
  • 71
  • means its not possible ... and legal iphone 4 devices and its also mean that apple didn't accept those app – Appz Venture Mar 24 '11 at 19:48
  • thanks i got it and i said to my client that no its not possible because client presure me to set the background .. thanks in advance. – Appz Venture Mar 25 '11 at 11:19
2

If you are talking about the iPhone background while you are outside of the app this is a repeat question. Otherwise in your own application just set contents of your root views layer to the CGImage you wish.

Setting iPhone wallpaper (locked screen background) programmatically?

How to set iPhone Wallpaper Programmatically

change wallpaper via iphone app

How to change wallpaper in iPad programmatically?

Community
  • 1
  • 1
Joe
  • 56,979
  • 9
  • 128
  • 135