加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 大数据 > 正文

vb 转换图片二进制数组

发布时间:2020-12-16 22:25:16 所属栏目:大数据 来源:网络整理
导读:'假设Form 上已经存在Picture1的控件,并已经设置好图片 Dim PBag As New PropertyBag Dim B() As Byte PBag.WriteProperty "Picture",Picture1.Picture '读取Picture1.Picture 图片并写到 Pbag 容器中 B = PBag.Contents '获取容器Byte 到 B() 数组中 '这时
'假设Form 上已经存在Picture1的控件,并已经设置好图片
Dim PBag As New PropertyBag
Dim B() As Byte
PBag.WriteProperty "Picture",Picture1.Picture
'读取Picture1.Picture 图片并写到 Pbag 容器中
B = PBag.Contents '获取容器Byte 到 B() 数组中
'这时 B 就时我们想要获得的Byte数组
'读取 Byte() 数组内容到 Picture
PBag.Contents = B '指定 PBag容器的内容
'读取容器中的图片

Set Picture1.Picture = PBag.ReadProperty("Picture")


出处:http://bbs.bccn.net/thread-248470-1-1.html

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读