ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Problem saving file in ImageEn's native format
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

yogiyang

India
727 Posts

Posted - May 17 2013 :  03:39:33  Show Profile  Reply
This problem is very random.

I have observed that when we save a file which has multiple layers in ImageEn's own native format at time the file just does not get saved.

But if we resave the file it gets saved properly.

Why must this be happening?

As I said before this problem is random and it is not possible to duplicate it.

It was actually reported by a customer who is using a software in which I am using ImageEn for handling images and their processing.

TIA

Yogi Yang


Yogi Yang

fab

1310 Posts

Posted - May 20 2013 :  02:16:18  Show Profile  Reply
Unfortunately it can be caused by several factors.
SaveToXXX methods are composed by sequences of Stream.Write calls. They can fail (raising exceptions) when a network share is not available, on disk problems (full, not enough rights...), etc...
Have you surrounded SaveToXXX by an empty try..except?
Go to Top of Page

yogiyang

India
727 Posts

Posted - May 20 2013 :  08:05:03  Show Profile  Reply
No I have now wrapped the file saving code in try..except block.

But then I am not getting any errors while saving the file.

If I re-save the file it gets saved OK!

Regards,

Yogi Yang


Yogi Yang
Go to Top of Page

fab

1310 Posts

Posted - May 20 2013 :  08:06:51  Show Profile  Reply
Do you get a zero-sized file?
Go to Top of Page

yogiyang

India
727 Posts

Posted - May 20 2013 :  08:28:45  Show Profile  Reply
Onitsavesaround4bytes!


Yogi Yang
Go to Top of Page

fab

1310 Posts

Posted - May 20 2013 :  08:31:05  Show Profile  Reply
Please send the resulting file (or post the hex content).
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: