开发者

image not showing in UIBUtton

开发者 https://www.devze.com 2022-12-15 01:16 出处:网络
I\'m writing a small application that allows for patterns to be placed on a button. When I run the app in the simulator the patterns display ok on the button. When I compile the application to the dev

I'm writing a small application that allows for patterns to be placed on a button. When I run the app in the simulator the patterns display ok on the button. When I compile the application to the device the patterns do not display on the buttons but all other logic behind the buttons works fine.

The patterns are simple png images and I use the basic code:

[orangeButton setImage:[UIImage imageNamed:@"circle.png"] forState:UIControlStateNormal]开发者_Go百科;

to add the patterns to the buttons.

To bring the patterns into Xcode I have just dragged them from the desktop to the resources folder in Xcode.

Why are the patterns displayed in the similuator but not the provisioned application?


The device is case-sensitive, the Mac is not; this may be the problem.

0

精彩评论

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