当前位置:首页 > 开发 > C# > 正文内容

C# pictureBox 设置图片的几种方式

C#5年前 (2021-08-25)
            string imUrl = @"http://www.pythonopen.com/1.ico";
            this.pictureBox1.ImageLocation  = imUrl;
            string imPath = @"D:\WaltzTool\驻留\图标\彩虹头像\favicon_32x.ico";
            this.pictureBox1.ImageLocation = imPath;
            string imPath = @"D:\WaltzTool\驻留\图标\彩虹头像\favicon_32x.ico";
            this.pictureBox1.Image = Image.FromFile(imPath);
            this.pictureBox1.Image = CCon_20210821.Properties.Resources.bilibili;


转载请注明出处。

本文链接:http://www.pythonopen.com/?id=160

相关文章

C# 正则表达式

命名空间    using System.Text.Regu...

C# 可空参数

using System; using System.Runtime.Inte...

C# 跳出foreach循环

在 C# 中,如果你想在 foreach 循环内部提前跳出当前这一轮循环,继续执行下一轮循环,可以使...

C# BackgroundWorker,在DoWork里更新控件内容

一般情况下不可以直接在BackgroundWorker的DoWork事件中更新 UI 控件在Back...

C# ref 和out

ref关键字概念:ref是 C# 中的一个关键字,用于按引用传递参数。当在方法调用中使用ref关键字...

C# 控件判断鼠标位置

        //...