dlg1.ShowPrinter ' <=====dialog to select printer
dim s as string
s="this is a sample"
Printer.Orientation = ori '<==== portrait/landscape
Printer.RightToLeft = rtl '<==== direction of printing
Printer.Print s
Printer.NewPage
Printer.Print "This is on a 2nd page"
Printer.EndDoc