Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/objective-c/25.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Iphone 如何在UIImageView中设置图片_Iphone_Objective C_Cocoa - Fatal编程技术网

Iphone 如何在UIImageView中设置图片

Iphone 如何在UIImageView中设置图片,iphone,objective-c,cocoa,Iphone,Objective C,Cocoa,我需要设置一个图像视图在这里显示图像 else if (n == 2) { gamestatus.text = @"The Card is A Two."; // I Need to set my imageview to a picture here. } 或者,如果已声明imageView myImageView.image = myImageHere; 编辑:回答有关如何设置图像的问题 一个简单的方法(有些人会说它有点低效) 或者,如果已声明imageView myIm

我需要设置一个图像视图在这里显示图像

else if (n == 2) {
    gamestatus.text = @"The Card is A Two.";
    // I Need to set my imageview to a picture here.
}
或者,如果已声明imageView

myImageView.image = myImageHere;
编辑:回答有关如何设置图像的问题

一个简单的方法(有些人会说它有点低效)

或者,如果已声明imageView

myImageView.image = myImageHere;
编辑:回答有关如何设置图像的问题

一个简单的方法(有些人会说它有点低效)

myImageView.image = [UIImage imageNamed:@"my Example Image.png"];