Results 1 to 5 of 5

Thread: Printing TextBox

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Aug 1999
    Location
    Ilirska Bistrica, Slovenia
    Posts
    242

    Post

    Hello!

    I know it's kind a stupid question and it looks that I'm rookie in VB, but I forgot it. I forgot how can I print text from textbox. Can anyone help me?
    I know it seems like I've just installed VB, but I haven't used those printing functions for text box for over a year and I forgot all.

    Zvonko
    Zvonko Bostjancic
    Ilirska Bistrica, Slovenia
    [email protected]
    Using VS6 Professional with SP3
    Programming mostly in VB and I've started to learn VC++ & MFC

  2. #2
    Hyperactive Member MPrestonf12's Avatar
    Join Date
    Jun 1999
    Location
    NY
    Posts
    330
    Try this syntax
    printer.print text1.text
    Matt

  3. #3
    Guest
    Try:

    Code:
    Printer.Print Text1.text 'Print text
    Printer.EndDoc 'Do not print blank pages (this is if the user presses return to a new page)

  4. #4
    Guest
    It's a good idea to set the Font and Position as well.
    Code:
    'Set the X and Y postions to a 1x1" border
    Printer.CurrentX = 1440
    Printer.CurrentY = 1440
    Printer.FontName = Text1.FontName
    Printer.FontSize = Text1.FontSize
    'You can also use FontItalic, FontStrikeThru and FontUnderline
    Printer.FontBold = Text1.FontBold
    Printer.Print Text1.Text
    Printer.EndDoc
    The EndDoc method will begin printing directly after the message has been sent. If you do not include it, the Printer will only print when your Application closes.

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Aug 1999
    Location
    Ilirska Bistrica, Slovenia
    Posts
    242
    Thanks, guys...
    You're soooooo good...
    Zvonko Bostjancic
    Ilirska Bistrica, Slovenia
    [email protected]
    Using VS6 Professional with SP3
    Programming mostly in VB and I've started to learn VC++ & MFC

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