Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using a TIFF file like a BMP file

Status
Not open for further replies.

estatefacts

Programmer
May 22, 2002
11
0
0
US
Hello,
I am trying to figure out how to load a TIFF file into an Image object so that I can print it out using VB6. I already know how to do this with a BMP file. I have read several threads that refer to downloading and using the imageeditor (I may not have spelled this correctly) and I have the imageeditor. But I have not seen any messages that tell how to use the imageeditor and most importantly the code examples that shows how to use it. For example I know how to do this:

Code:
Image1.Picture = LoadPicture("C:\Picture Files\Picture_of_Airplane.bmp")

Code:
Printer.PaintPicture Image1.Picture, 0, 0, Printer.ScaleWidth, Printer.ScaleHeight

But I have no idea how to do the above or something similar with a TIFF file.

Thank you so much for reading this message and for your help!
 
Instead of using a picture box use a Wang Image Edit control if you have it installed - it comes standard for WindowsNT4 (but is not present on Xp).

Where Img1 is the name of the control

Img1.Image=Pathname of tiff file
Img1.FitTo 0,true
Img1.Display

The control also features a selection zoom facility.

Private Sub Img1_SelectionRectDrawn (byVal Left as Long, byVal Top as Long, byVal Width as Long, byVal Height as Long)

Img1.ZoomToSelection

End Sub

Hope this proves useful.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top