hi just finished my first project and it was quite a journey (hahaha, considering its my first time to do it. Just wanna ask, with this code:.....

Private Sub PrintDocument1_PrintPage(ByVal sender As System.Object, ByVal e As System.Drawing.Printing.PrintPageEventArgs) Handles PrintiTicket.PrintPage

        e.Graphics.DrawString("COUNTER 17.Your number is " & iTicket, TextBox1.Font, Brushes.Blue, 50, 50)
    End Sub

.... i was able to print the text that i want, but is it possible that it be printed in three lines? i mean on the first line, the text "Counter 17", and in the second line with a smaller font size, "Your number is" and on the third line with a bigger font size the "& itictet portion"?

ive read lots of tutorial but i guess, nothing tackles about this one. Thank you so much in advance.

Recommended Answers

For an excellent article on this please see Printing With VB 2010

Jump to Post

All 2 Replies

You can also try:

e.Graphics.DrawString("COUNTER 17" & Environment.NewLine & "Your number is " & Environment.NewLine & iTicket, TextBox1.Font, Brushes.Blue, 50, 50)
Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.