Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/fortran/2.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
Ios 如何在objective-c中将UIImage设置为空_Ios_Objective C_Uiimageview - Fatal编程技术网

Ios 如何在objective-c中将UIImage设置为空

Ios 如何在objective-c中将UIImage设置为空,ios,objective-c,uiimageview,Ios,Objective C,Uiimageview,我使用了以下代码: UIImage*选择图像 那么 然后如何将UIImage设置为空值。不要将UIImage设置为空值,而是将图像设置为空图像 [UIImage ImageName:@]如果只想将图像设置为空,只需执行以下操作: yourImage=nil 如果我误解了这个问题,或者我错了,请毫不犹豫地告诉我 您想将其从视图中删除,还是只想设置空图像?如何执行该代码不清楚您想要什么?您想将哪个图像设为空?选择edimage?ui图像名称作为selectedimageUIImageView*子视图

我使用了以下代码: UIImage*选择图像

那么

然后如何将UIImage设置为空值。

不要将UIImage设置为空值,而是将图像设置为空图像


[UIImage ImageName:@]

如果只想将图像设置为空,只需执行以下操作:

yourImage=nil


如果我误解了这个问题,或者我错了,请毫不犹豫地告诉我

您想将其从视图中删除,还是只想设置空图像?如何执行该代码不清楚您想要什么?您想将哪个图像设为空?选择edimage?ui图像名称作为selectedimageUIImageView*子视图。image=[uiimage imagename:@];这将设置一个空图像。
for (int j = 1 ; j <=b ; j++){
        id subView = [self.view viewWithTag:j];

        if ([subView isKindOfClass:[UIImageView class]]){
            ((UIImageView *)subView).image = selectedImage;