CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2001
    Posts
    254

    Print of picture

    I 've wriiten a Personnel Program wherein u can enter a staff number if found will display
    the scanned staff photo,.problem is

    1. using the Printer.Print object how can I print the current displayed picture with current
    displayed staff info
    2. using the Data Report that comes with the VB6 how can I print the current displayed pictures with
    staff current displayed staff info

    all pictures that were scanned are stored in HDD ie. C:\pictstaff

    thanks

    cyrus


  2. #2
    Join Date
    Jan 2000
    Location
    Olen, Belgium
    Posts
    2,477

    Re: Print of picture

    This code uses the printer object:
    Make sure you have 4 textboxes on the form called txtName, txtAddress, txtRemarks and txtPathToPicture. The last one must contain the path to the picture file.

    Printer.print "Name: " & txtName.text
    Printer.print "Address: " & txtAddress.text
    Printer.print "Remarks: " & txtRemarks.Text
    Printer.PaintPicture LoadPicture(txtPathToPicture), Printer.CurrentX, Printer.CurrentY
    Printer.EndDoc





    Tom Cannaerts
    [email protected]

    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to produce bigger and better idiots. So far, the universe is winning -- Rich Cook
    Tom Cannaerts
    email: [email protected]
    www.tom.be (dutch site)

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

Featured