[Gambas-user] Image storing and retrieving

Benoit Minisini gambas at ...1...
Wed Oct 5 21:39:28 CEST 2005


On Monday 03 October 2005 12:58, Marcelo Confortino wrote:
> Hi! Does anybody know how to store and retrieve an image in a MySQL
> table? I succeeded in storing a jpeg in a medium blob or blob column,
> using the 'load_file' MySQL function, but when I try to move the blob to
> a PictureBox I get the message 'Wanted picture, got string instead'. Any
> ideas? Thanks.
>

Blobs are not supported yet, because of the many differences between the 
different DBMS.

Try to:
- Put the blob string in a temporary file.
- Give this file an extension that matches the picture format.
- Load the file in a Picture object.
- Set MyPictureBox.Picture with this picture object.

Regards,

-- 
Benoit Minisini





More information about the User mailing list