如何找到图片框控件已使用图像初始化 [英] how to find that picturebox control is initialized with image

查看:54
本文介绍了如何找到图片框控件已使用图像初始化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在运行时添加图像.如果picturebox包含图像,则启用窗体上的其他控件;如果picturebox中没有图像,则禁用该控件,以便如何找到使用image初始化picturebox控件.

i am adding images at runtime. if the picturebox contains images the other control on form are enable if there is no image in picturebox the controls are disable so how can i find that picturebox control is initialized with image.

推荐答案

if (pictureBox1.Contains("YourImage"))
            {
                // load the other control (i.e TextBox1.enable=true)
            }
 else
            {
                //TextBox1.enable=false;
            }


这篇关于如何找到图片框控件已使用图像初始化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆