Hi everyone,
I'm having an issue with adding an image to a report. This is code of the report
<pageGraphics>
<image x="37" y="37" height="50" width="110" file="../img/logo-coolabora.png" />
...
</pageGraphics>
And this is the error shown as I try to generate the PDF:
cannot identify image file
fileName=<open file u'C:\\Archivos de programa\\OpenERP 7.0-20140221-003045\\Server\\server\\openerp\\addons\\ajuste_did\\img\\logo-coolabora.png', mode 'r' at 0x03799E90> identity=[ImageReader@0x392ed50 filename=u'C:\\Archivos de programa\\OpenERP 7.0-20140221-003045\\Server\\server\\openerp\\addons\\ajuste_did\\img\\logo-coolabora.png']
handle_pageBegin args=()
(<type 'exceptions.IOError'>, IOError("cannot identify image file\nfileName=<open file u'C:\\\\Archivos de programa\\\\OpenERP 7.0-20140221-003045\\\\Server\\\\server\\\\openerp\\\\addons\\\\ajuste_did\\\\img\\\\logo-coolabora.png', mode 'r' at 0x03799E90> identity=[ImageReader@0x392ed50 filename=u'C:\\\\Archivos de programa\\\\OpenERP 7.0-20140221-003045\\\\Server\\\\server\\\\openerp\\\\addons\\\\ajuste_did\\\\img\\\\logo-coolabora.png']\n handle_pageBegin args=()",), <traceback object at 0x03933F30>)
I've read on the web that this is an issue due to some Python's library... Can someone help me?
Thanks in advance.
SOLUTION:
As @Jeudy said, I used an url like this:
<image x="37" height="37" height="50" width="110" file="http://localhost:8069/[module_name]/static/img/[image_name.image_format]" />
Thanks @Jeudy! it worked for me the solution in the "EDIT" part of the question.