<div dir="ltr">Thank you Juraj for your answer!<div><br></div><div>I tried to run your code from within Scribus and it failed with the same error as mine!</div><div>It may be you're right, and the python that scribus uses cannot find PIL module. I'll try to work on that!</div><div><br></div><div>I'm sorry I didn't include info about OS and Scribus version...newbie mistake!</div><div>I'm running Scribus 1.4.5 on Windows7!</div><div><br></div><div>I'll let you guys know if I'll be able to work this out!</div><div>Thanks!</div><div><br></div><div>Andrea</div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-04-01 9:00 GMT+02:00 Juraj Fedel <span dir="ltr"><<a href="mailto:wtxnh-scribus@yahoo.com.au" target="_blank">wtxnh-scribus@yahoo.com.au</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Fri, Apr 01, 2016 at 02:10:19AM +0200, Andrea Marcon wrote:<br>
> I managed to get what I need from Python directly, using pyBarcode<br>
> (actually I've used a fork - viivakoodi<br>
</span>> <<a href="https://pypi.python.org/pypi/viivakoodi" rel="noreferrer" target="_blank">https://pypi.python.org/pypi/viivakoodi</a>>), saving the barcode images and<br>
<span class="">> then importing them in Scribus by means of another script.<br>
<br>
</span>From website i learned that viivakoodi depends on PIL to write png<br>
image.<br>
<br>
I created simple script from example provided by viivakoodi :<br>
=== bar.py<br>
import barcode<br>
from barcode.writer import ImageWriter<br>
ean = barcode.get('ean13', '123456789102', writer = ImageWriter())<br>
filename = ean.save('ean13')<br>
====<br>
<br>
When i run this script from scribus as:<br>
scribus-1.5.2.svn -g -py bar.py<br>
i do find ean13.png file created.<br>
This script also produce desired png if I run scrip from scribus using<br>
GUI menu (Scripter -> Execute Script ...)<br>
<br>
It is hard to guess why you have your problem. Next time try to include<br>
info about OS you are running on, python version, scribus version etc...<br>
<br>
If you are on Windows platform, it might be that python you run your<br>
script manualy, and the one you run from scribus is not the same and<br>
later one can not find PIL library. I would restrain myself from further<br>
guessing about environment you run your programs on.<br>
<span class="HOEnZb"><font color="#888888"><br>
Juraj<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
___<br>
Scribus Mailing List: <a href="mailto:scribus@lists.scribus.net">scribus@lists.scribus.net</a><br>
Edit your options or unsubscribe:<br>
<a href="http://lists.scribus.net/mailman/listinfo/scribus" rel="noreferrer" target="_blank">http://lists.scribus.net/mailman/listinfo/scribus</a><br>
See also:<br>
<a href="http://wiki.scribus.net" rel="noreferrer" target="_blank">http://wiki.scribus.net</a><br>
<a href="http://forums.scribus.net" rel="noreferrer" target="_blank">http://forums.scribus.net</a><br>
</div></div></blockquote></div><br></div>