borderAndreaVB free resources for Visual Basic developersborder
borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2016 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (How can print PDF file automatically?)Next Topic (crystal report load an image) New Topic New Poll Post Reply
AndreaVB Forum : Printing : print TIF picture
Poster Message
humberto
Level: Wizard

Registered: 13-01-2005
Posts: 254

icon print TIF picture

Hi,


I need to write a LabView application that take TIF picture file from
a disk and print it using the default printer which is connecting to
the computer.


Any idea how to do something like this ?


Thank you,


[Edited by humberto on 26-01-2005 at 06:26 PM GMT]

26-01-2005 at 05:24 PM
View Profile Send Email to User Show All Posts | Quote Reply
Goran
Level: Moderator

Registered: 16-05-2002
Posts: 1652
icon Re: print TIF picture

Load image in PictureBox controla and use Printer's PaintPicture method to print graphics on printer, followed by the EndDoc method.

____________________________
If you find the answer helpful, please mark this topic as solved.

26-01-2005 at 11:06 PM
View Profile Send Email to User Show All Posts | Quote Reply
humberto
Level: Wizard

Registered: 13-01-2005
Posts: 254
icon Re: print TIF picture

That is what I thought but an PictureBox control  can not load
tif when i try to load i get (Invalid picture) Msg

27-01-2005 at 06:31 AM
View Profile Send Email to User Show All Posts | Quote Reply
Goran
Level: Moderator

Registered: 16-05-2002
Posts: 1652
icon Re: print TIF picture

Interesting....I can load it with no problems. I didnt have any tiff image on computer, so I downloaded it from internet, and I am not sure if it IS tiff image or someone just change its extension. I tried it in design time (chaning type to all files, not just image files), and in run time with LoadPicture method.
If oyu still cant load tiff directly, then the next step will be using GDI+, I cant think of any other way.....

____________________________
If you find the answer helpful, please mark this topic as solved.

27-01-2005 at 12:03 PM
View Profile Send Email to User Show All Posts | Quote Reply
humberto
Level: Wizard

Registered: 13-01-2005
Posts: 254
icon Re: print TIF picture

Goran,
Try this one

____________________________
Attached:
Test.zip 3 KB (Downloads: 55)

27-01-2005 at 12:24 PM
View Profile Send Email to User Show All Posts | Quote Reply
Goran
Level: Moderator

Registered: 16-05-2002
Posts: 1652
icon Re: print TIF picture

Nope, you were right, it seems that it wasnt the real tiff image I downloaded. Then, I cant think of any other way than to use GDI library. Try this link to see how it works

____________________________
If you find the answer helpful, please mark this topic as solved.

27-01-2005 at 05:26 PM
View Profile Send Email to User Show All Posts | Quote Reply
humberto
Level: Wizard

Registered: 13-01-2005
Posts: 254
icon Re: print TIF picture

Thanks Goran i will look the link


[Edited by humberto on 27-01-2005 at 07:44 PM GMT]

27-01-2005 at 06:43 PM
View Profile Send Email to User Show All Posts | Quote Reply
humberto
Level: Wizard

Registered: 13-01-2005
Posts: 254
icon Re: print TIF picture

Thanks Goran this work fine

28-01-2005 at 01:12 PM
View Profile Send Email to User Show All Posts | Quote Reply
Goran
Level: Moderator

Registered: 16-05-2002
Posts: 1652
icon Re: print TIF picture

Im glad It was helpful.  

____________________________
If you find the answer helpful, please mark this topic as solved.

28-01-2005 at 02:09 PM
View Profile Send Email to User Show All Posts | Quote Reply
someimage
Level: Trainee

Registered: 17-07-2013
Posts: 1
icon Re: print TIF picture

some graphic program can't load tiff images, so it would be impossible to print tiff picture vb.net. so first you need to find a useful container customised for tiff.  for example tiff viewer.print tiff picture vb.net

17-07-2013 at 10:19 AM
View Profile Send Email to User Show All Posts | Quote Reply
pittypan
Level: Protégé

Registered: 07-02-2014
Posts: 5
icon Re: print TIF picture

Since you have solved the tiff printing issue, do not forget to mark it as solved.

[Edited by pittypan on 03-03-2014 at 04:22 AM GMT]

03-03-2014 at 04:18 AM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : Printing : print TIF picture
Previous Topic (How can print PDF file automatically?)Next Topic (crystal report load an image) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
borderAndreaVB free resources for Visual Basic developersborder
borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2016 Andrea Tincaniborder