[reportlab-users] Drawing and Canvas (rlbarcode)

Armando Roque dropsdef at gmail.com
Tue Sep 26 13:26:43 EDT 2006


Robin Becker wrote:
> Armando Roque wrote:
>> Hi,
>>
>> I'm new Python and reportlab.
>> Is possible create barcode with Drawing?
>> I try and get error (assertion), my code:
>>
>>
>> bolet=Drawing(210*mm,297*mm)
>> ...
>> story = [I2of5('12345678901234567890123456789012345678901234', xdim =
>> 0.5*mm, checksum=1, bearers=0)]
>>
>> frame = Frame(mm, mm, 250*mm, 250*mm, showBoundary=0))
>> bolet.add(story, frame)
>>
>> I follow example of rlbarcode.
>>
>> Anyone can help me?
>>
>> Regards,
>>
> well without the error it's fairly hard to give advice
Opps... sorry,

  File "boleto.py", line 416, in ?
    boleto.add(story, frame)
  File "/usr/lib/python2.4/site-packages/reportlab/graphics/shapes.py",
line 346, in add
    assert isValidChild(node), "Can only add Shape or UserNode objects
to a Group"
AssertionError: Can only add Shape or UserNode objects to a Group

Thanks,

-- 

Armando Roque
http://dropsdef.blogspot.com
msn: dropsdef at gmail.com
skype: dropsdef



More information about the reportlab-users mailing list