How to print label using dymo label printer (ESC commands )

Here I need to print label with barcode . For that I used Dymo label printer to print label.

dim p as PixmapShape p=new PixmapShape(Pic) p.Rotation=3.14/2 p.x=-20 p.y=670 g.DrawObject(p)
This code prints barcode but that doesn’t scan,returns wrong value. Another way to use esc commands for Dymo label printer . Any one know that how to use ESC commands for dymo label printer in xojo ?

See this: (from Tim H)

[quote]Here’s a sample project that encapsulates those declares in a module to make them easier to call:

And this:

from page 35

Essentially, (for a 10 chracter code) you send something like chrb(27) chrb(107) chr(2) chr(10) then 10 characters