开发者

Load image from memory into VB6 PictureBox

开发者 https://www.devze.com 2022-12-10 14:11 出处:网络
I\'m not a VB6 developer so excuse me if I\'m not making any sense. If I have a VARIANT array of bytes开发者_JS百科 containing an RGB array of image data, is it possible to get that data to be displa

I'm not a VB6 developer so excuse me if I'm not making any sense.

If I have a VARIANT array of bytes开发者_JS百科 containing an RGB array of image data, is it possible to get that data to be displayed in a PictureBox? The PictureBox documentation suggests that the only acceptable sources are files.

Additionally, the image size and other image information is known.


The PictureBox documentation lies. But unfortunately, it’s not pretty to create an IPictureDisp in memory. The following link may help you – unfortunately, it’s in German:

How to create a picture from data in memory


There may be a better (i.e. faster) method, but you should look in to the PSet method of a picture box control.

PSet method of picture box control

0

精彩评论

暂无评论...
验证码 换一张
取 消