调用程序中的资源中的图片文件

 

 

 

 

调用代码:
head为head.png的文件名

        private void button1_Click(object sender, EventArgs e)
        {
            Image img1 = global::WindowsFormsApplication4.Properties.Resources.head;
            button1.Image = img1;
        }

 

posted @ 2013-12-04 12:38  XE2011  阅读(214)  评论(0编辑  收藏  举报