use this to print text
` ######################## Print Text in DB
` (c) by Hubdule/Color Arts 2002
` ######################## Print Text in DB
sync on
sync rate 0
cls
hide mouse
` ########################################################
` Here we create the file we want to print
` ########################################################
` Filename ...
dateiname$="print.dat"
` Test if it exist ... if yes then delete
if file exist(dateiname$) then delete file dateiname$
` open file
open to write 1,dateiname$
` print anything into it
write string 1,"Das ist ein Test"
` If it's ready close file
close file 1
sync
` ########################################################
` ########################################################
` how to use the printer ...
` ########################################################
` This method only works on local printers (no network stuff)
` use EXECUTE FILE Filename, Commandline, Directory to print the file
batname$="d.bat"
if file exist(batname$) then delete file batname$
open to write 1,batname$
` to print on LPT1 use
write string 1,"TYPE "+dateiname$+" > LPT1"
` to print on LPT2 use
` write string 1,"TYPE "+dateiname$+" > LPT2"
` to print on LPT3 use
` write string 1,"TYPE "+dateiname$+" > LPT3"
` to print on LPT4 use
` write string 1,"TYPE "+dateiname$+" > LPT4"
close file 1
sync
if file exist(batname$) then EXECUTE FILE batname$,"",""
sync
end