Results 1 to 5 of 5

Thread: Set max lines to print ??

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Feb 2006
    Posts
    6

    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:
    1. Me.rtbPrintInfo.SelFontName = "Courier New"
    2. 'Me.rtbPrintInfo.SelFontSize = 7
    3. Me.rtbPrintInfo.LoadFile fileName, rtfText
    4.  
    5. Dim NumCopies As String
    6. Dim Index As Integer
    7. Dim printDlg As PrinterDlg
    8. Dim NewPrinterName As String
    9. Dim objPrinter As printer
    10. Dim strsetting As String
    11.  
    12. Set printDlg = New PrinterDlg
    13.  
    14. printDlg.printerName = printer.DeviceName
    15. printDlg.DriverName = printer.DriverName
    16. printDlg.Port = printer.Port
    17. printDlg.PaperBin = printer.PaperBin
    18. 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
  •  



Click Here to Expand Forum to Full Width