I would like to embed an Image, which is stored in a BLOB Field of a MySQL DB. In my first step I tried do do that with following code:
var myImage : Image = new Image();
myImage.source = workClient.logo_file;
myImage.width = 200;
myImage.height = 25;
p.addImageStream(myImage as ByteArray,ColorSpace.DEVICE_RGB,null,myPrintItem.posx,myPrintItem.posy,myPrintItem.width,myPrintItem.height,0,0,"Normal",null);
This brought up an Error #1009: Cannot access a property or method of a null object reference
The stored Image can be used within the source Property of an Image-Object and also can be displayed on Screen (as workaround I am displaying the Image and use the addImage function from AlivePdf, but this approach is not really usable, if I have to load more pictures).
Does anybody know what's the best Practice to add an Image from a ByteArray to AlicePDF.