Multi page Tiff editing

Discussions about document viewing.
Post Reply
JensN
Posts: 12
Joined: Wed Feb 16, 2011 11:43 am

Multi page Tiff editing

Post by JensN » Tue Aug 09, 2011 1:12 pm

We have an Image viewer which consists of a GdViewer and a ThumbailEx.
We load all files (JPEG or TIFF) by using:

Code: Select all

int imageId = gdPictureImage.CreateGdPictureFromStream(memoryStream);
gdViewer.DisplayFormGdPictureImage(imageId);
thumbnailEx.LoadFromGdViewer(gdViewer);
This works fine so far.
The problem starts if we want to edit one of the pages.
Therefor we use the following code:

Code: Select all

gdPictureImage.Rotate(imageId, RotateFlipType.xxx);
gdViewer.Redraw();
thumbnailEx.RedrawItem(gdPictureImage.TiffGetCurrentPage(imageId) - 1);
After the call the image in the viewer is rotated.
But the thumbnailEx seems to be disconnected from the GdViewer. Suddenly the first page is focused and the selected page is no longer shown in the GdViewer.

Thanks in Advance!
Jens

JensN
Posts: 12
Joined: Wed Feb 16, 2011 11:43 am

Re: Multi page Tiff editing

Post by JensN » Wed Aug 10, 2011 10:51 pm

Can anyone help? We didn't found a solution so far...

User avatar
Loïc
Site Admin
Posts: 5881
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: Multi page Tiff editing

Post by Loïc » Fri Aug 12, 2011 12:52 am

Hi,

Before:

Code: Select all

int imageId = gdPictureImage.CreateGdPictureFromStream(memoryStream);
You must add:

Code: Select all

gdPictureImage.TiffOpenMultiPageForWrite()
Let me know if the problem persists.

Kind regards,

Loïc

JensN
Posts: 12
Joined: Wed Feb 16, 2011 11:43 am

Re: Multi page Tiff editing

Post by JensN » Fri Aug 12, 2011 1:35 pm

Hi Loïc,

thank you very much.
After adding this line of code everything works fine.

Thanks again,

Jens

User avatar
Loïc
Site Admin
Posts: 5881
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: Multi page Tiff editing

Post by Loïc » Fri Aug 12, 2011 6:30 pm

Ok perfect !

Thank you for the return.

Kind regards,

Loïc

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests