Recommended way to determine if save is completed

Questions, comments and suggestions concerning VintaSoft Imaging .NET SDK.

Moderator: Alex

Post Reply
smithsw
Posts: 11
Joined: Fri Mar 19, 2010 9:21 pm

Recommended way to determine if save is completed

Post by smithsw » Tue Jun 15, 2010 3:01 am

I'm using code from the Image Viewer Demo (v4.2) saveCurrentImageToolStripMenuItem_Click function to save the image file back to the source file. What is the best way to determine if the image save process has completed? I need to make sure the file save process is complete before the application moves the image file to it's final destination on the server.

If the progress value in UpdateSavingImagesProgress = 100, does that do it? I noticed that this value will hit 100 without running through the function above (for example when rotating a page) but the changes are not saved back to the source file until the code in that function is run.

Thanks,

Shane

Alex
Site Admin
Posts: 1461
Joined: Thu Jul 10, 2008 2:21 pm

Re: Recommended way to determine if save is completed

Post by Alex » Tue Jun 15, 2010 8:29 am

Hello Shane,
If the progress value in UpdateSavingImagesProgress = 100, does that do it? I noticed that this value will hit 100 without running through the function above (for example when rotating a page) but the changes are not saved back to the source file until the code in that function is run.
100% progress means that all images from image collection were processed. You must subscribe to the ImageCollectionSaved event if you want to know when image collection was saved.

Best regards, Alexander

smithsw
Posts: 11
Joined: Fri Mar 19, 2010 9:21 pm

Re: Recommended way to determine if save is completed

Post by smithsw » Tue Jun 15, 2010 5:52 pm

So I'm assuming that once that the event created by:

Code: Select all

AddHandler encoder.ImageCollectionSaved, New ImageCollectionSavedEventHandler(AddressOf encoder_ImageCollectionSaved)
is raised (which finally ends up in the sub ChangeSourceStreamToSaveStream), I can safely assume the image collection is saved and the file is ready to be closed and moved.

Alex
Site Admin
Posts: 1461
Joined: Thu Jul 10, 2008 2:21 pm

Re: Recommended way to determine if save is completed

Post by Alex » Thu Jun 17, 2010 8:09 am

Hello Shane,

Yes, file is ready to be closed and moved after the ImageCollectionSaved event.

Best regards, Alexander

vincomgo
Posts: 1
Joined: Mon Jul 05, 2010 7:23 am

Re: Recommended way to determine if save is completed

Post by vincomgo » Mon Jul 05, 2010 7:46 am

hi,is it invalid yet:-?
---------
Dedicated JAVA Developers

Alex
Site Admin
Posts: 1461
Joined: Thu Jul 10, 2008 2:21 pm

Re: Recommended way to determine if save is completed

Post by Alex » Wed Jul 07, 2010 8:10 am

Hello,
hi,is it invalid yet:-?
What do you mean?

Best regards, Alexander

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest