Printing to printer with MIRC Encoding font
Posted
#1
(In Topic #355)
Enthusiast

this is taken from printing_example 0.1.0
Public Sub PrinterOne_Draw()
Paint.Font = Font["MIRC Encodeing,12"]
Paint.DrawText(TextArea1.Text, 10, 10)
End
and it is giving me trouble …. I am new still learning Gambas
Posted
Enthusiast

Paint.Font = Font["MICR Encoding,+10"]
it Kinda works …. not the first time … but it works the second time I print it ???
Posted
Enthusiast

Printer is not printing in Main: 21
If I select Print Preview and then select print from the preview it will print on the Printer
I also need the command to force a Page break to print second and third, etc. ,,,,Pages
Any help would be appreciated
Public Sub Prn1_Draw()
Dim ix, iCkNumber, ibankroute, iaccountNumber, iStartCkNum As Integer
Dim mircnumber As String
iCkNumber = 25508
Paint.End
Paint.Begin(Prn1)
For ix = 0 To 400 Step 200
Paint.Font = Font["Aeral,12,bold"]
Paint.DrawRichText(iCkNumber, 480, 25 + ix)
Inc iCkNumber
Paint.Font = Font["Aeral,9"]
Paint.DrawrichText("<b>John Doe JR.</b><br> 1234 Main Sr. <br>Hometown Il 66152", 210, 35 + ix)
Paint.DrawrichText("<u>Date______________________ </u>", 390, 65 + ix)
Paint.DrawrichText("<small>Pay to the<br><u>order of:</u></small><u>_______________________________________________________________|</u>", 190, 80 + ix)
Paint.DrawrichText("<h3>$<u>________________</u></h3> ", 472, 88 + ix)
Paint.DrawrichText("<u>______________________________________________________________________________<small>Dollars</small></u>", 190, 120 + ix)
Paint.Font = Font["MICR Encoding,18"]
mircnumber = Str("a7200012345a c8543987c") & Str(iCkNumber)
Paint.DrawRichText(mircnumber, 197, 200 + ix)
Next
' need command to send page break to printer ???
Paint.End
End
Public Sub Button1_Click()
If Prn1.Configure() Then Return
Prn1_Draw
End
Posted
Regular

Posted
Enthusiast

is that the farm?
Posted
Regular

grayghost4 said
where is the project showcase ?
Home > Board Index > Gambas Programming > General > Project Showcase
Or use this link: https://forum.gambas.one/viewforum.php?f=13
Posted
Enthusiast

Posted
Enthusiast

Is there a text book or tutorial that covers printing to the printer ? I have been searching for such a thing.
I guess what I am looking for is how to Print "Hello world " to the printer
all the examples I find are to advanced for me to understand
Posted
Regular

https://en.wikibooks.o…_Gambas_from_Zip/Printing
1 guest and 0 members have just viewed this.



