Hi all,

Thought id share this with you as I was struggling with it a bit.

There are other posts about on how to write the resource to file but
in AX 2009 on Windows 2008 server I was having problems with security
so I wanted it to write straight from memory.

Here is the code if anyone struggles in the future:

Public display Bitmap ShowBox()
{

ResourceNode resourceNode =
SysResource::getResourceNode("ReportRect_jpg");
container nodeData;
Image img;
Bitmap bmp;

;

    if (resourceNode != null)
    {
        resourceNode.AOTload();
        nodeData = SysResource::getResourceNodeData(resourceNode);
        img = new Image(nodeData);
    }
return img.getData();
}

Cheers,
Jacques

Reply via email to