Need a way to programmatically get the number of pages in a TIF??

  • Thread starter Thread starter ganderso
  • Start date Start date
G

ganderso

Hi

I have a number of TIF files. I need to have a way to get the number of
pages in each file programmatically. Anyone know a control or app that
I can call to do this?

Thanks in advance.
Greg
 
Greg,

I haven't tried it but it looks like
System.Drawing.Image.GetFrameCount() will work. You might give it a try.

* Here is a link to something similar. May help you get started.
http://eggheadcafe.com/articles/stripimagefromanimatedgif.asp

* Here is some example VB.NET code
Dim img As Image =
System.Drawing.Image.FromFile("c:\Mike\Fax000000c8.TIFF")
Dim pages As Integer =
img.GetFrameCount(System.Drawing.Imaging.FrameDimension.Page)

Good luck!

Jason Newell
 
Back
Top