|
-
Mar 6th, 2006, 02:17 AM
#1
Thread Starter
New Member
Set max lines to print ??
Hi..I have problem with printing function in vb..
I have a program which will display data taken from the database and put into a flexgrid. Then, when user want to print it, they just choose which column to print..
Currently, the papersize set to the printer is Letter type. However, the user usually use A4 size paper to print instead of Letter type paper (I dunno why they don't want to use Letter paper ) and make the bottom line of the text blurred or half printed..
my question :
is there any way i can set the maximum line to print? and when it reached the max line, it will automatically go to the next page?? this is because the bottom line shud have at least 1 inch space..
this is the portion of my code :
(i have to use the printDlg function because the common dialog box just cannot work correctly in my program)
VB Code:
Me.rtbPrintInfo.SelFontName = "Courier New"
'Me.rtbPrintInfo.SelFontSize = 7
Me.rtbPrintInfo.LoadFile fileName, rtfText
Dim NumCopies As String
Dim Index As Integer
Dim printDlg As PrinterDlg
Dim NewPrinterName As String
Dim objPrinter As printer
Dim strsetting As String
Set printDlg = New PrinterDlg
printDlg.printerName = printer.DeviceName
printDlg.DriverName = printer.DriverName
printDlg.Port = printer.Port
printDlg.PaperBin = printer.PaperBin
printDlg.PaperSize = printer.PaperSize
Last edited by Hack; Mar 6th, 2006 at 07:54 AM.
Reason: Added [vbcode] [/vbcode] tags and for more clarity.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|