Page 1 of 2
Viewing a multi-page .tif
Posted: Thu Sep 23, 2021 8:51 am
by richardc
I need to display multi-page .tif files I am using DCHTMLVIEWER but it only displays the first page. Does anyone know of a way to accomplish this using eXpress and/or xBase++.
Thanks,
Richard
Re: Viewing a multi-page .tif
Posted: Thu Sep 23, 2021 9:43 am
by rdonnay
When I try to open the .TIF in Windows Edge Explorer, it reroutes it to the Windows Photo Viewer.
You may have to do it this way:
DC_SpawnUrl( 'c:\bhs\myfile.tif')
Re: Viewing a multi-page .tif
Posted: Thu Sep 23, 2021 3:54 pm
by richardc
Thanks Roger.
I am trying to allow users to view the multi-page .TIF files within the DCHTMLVIEWER and not have to spawn a new window. Maybe a .TIF to a .PDF conversion, then to the DCHTMLVIEWER?
Richard
Re: Viewing a multi-page .tif
Posted: Fri Sep 24, 2021 1:42 am
by skiman
Hi,
TIF isn't supported by most browsers, so it will be a problem with htmlviewer.
Converting to JPG, PNG or as you mentioned to PDF since it is a multi page will be the way to go.
Re: Viewing a multi-page .tif
Posted: Fri Sep 24, 2021 2:04 am
by Auge_Ohr
hi,
have a look at "Freeimage"
there is a Xbase++ Wrapper using Ot4XB see this Attachmen
viewtopic.php?f=2&t=2862&p=17108
Purpose of FreeImage
A clear picture about a project is important, because it is that picture that defines which
features are implemented and which are not.
FreeImage supports:
Loading and saving of as many bitmap types as possible
Easy access to bitmap components, such as palettes and data bits
Converting bitmap’s bit depths from one to another
Accessing pages in a bitmap when there are multiple, such as in TIFF
Basic manipulation of bitmaps, such as rotation, flipping and resampling or point
operations such as brightness and contrast adjustment
Alpha compositing and alpha blending
Re: Viewing a multi-page .tif
Posted: Fri Sep 24, 2021 5:26 am
by richardc
Thanks Jimmy. I will check Freeimage out.
Re: Viewing a multi-page .tif
Posted: Fri Sep 24, 2021 7:52 am
by richardc
I found a command line free product that converts from multi-page tiffs to a pdf. It is called nconvert. I am running it via Runshell() from within my application, doing a pdf conversion and then sending it to DCHTMLVIEWER. It is fast and works perfect.
Thanks for everyone's help.
Richard
Re: Viewing a multi-page .tif
Posted: Fri Sep 24, 2021 8:58 am
by rdonnay
It is fast and works perfect
I like quick, simple solutions. Good work.
Re: Viewing a multi-page .tif
Posted: Sun Sep 26, 2021 9:55 pm
by Eugene Lutsenko
richardc wrote: ↑Fri Sep 24, 2021 7:52 am
I found a command line free product that converts from multi-page tiffs to a pdf. It is called nconvert. I am running it via Runshell() from within my application, doing a pdf conversion and then sending it to DCHTMLVIEWER. It is fast and works perfect.
Thanks for everyone's help.
Richard
Richard! You have found a very useful utility and an excellent solution. Thank you very much!
Re: Viewing a multi-page .tif
Posted: Mon Sep 27, 2021 12:02 am
by skiman
Hi,
I found a command line free product that converts from multi-page tiffs to a pdf. It is called nconvert.
It is not free when you use it commercially!