Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Sunday, July 8, 2007 12:59:53 AM(UTC)
ITProjectConsulting

Groups: Registered
Posts: 7


Hi,

I have one strange problem. My application (developed in c # and using version 15 leadtools) until to month all worked correctly, now  marks me it the following exception when I use the method RasterCodecs.Save().

RasterCodecs.Save, Leadtools.RasterException: Not able to open file

   at Leadtools.RasterException.CheckErrorCode(Int32 code)

   at Leadtools.Codecs.RasterCodecs.SaveOnePage(Int32 page, SaveParams saveParams)

   at Leadtools.Codecs.RasterCodecs.DoSave(SaveParams saveParams)

   at Leadtools.Codecs.RasterCodecs.Save(RasterImage image, String fileName, RasterImageFormat format, Int32 bitsPerPixel)

   at Acquisizione.Dominio.MotoreRiconoscimento.SaveImage(RasterImage image_, String pathFile_, RasterImageFormat format_, Int32 bitPerPixel_)

 

Which it is the problem?

Thanks for the attention

 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Monday, July 9, 2007 4:07:21 AM(UTC)

Qasem Lubani  
Guest

Groups: Guests
Posts: 3,034

Was thanked: 1 time(s) in 1 post(s)

Can you check if you have permission to save files?
 
#3 Posted : Friday, June 27, 2008 3:48:22 AM(UTC)

Param  
Param

Groups: Registered
Posts: 1


Hi Lead Tools,

The Same problem occurs for me while saving the image in .Net . Even that folder have full rights to save/delete/create the new file , but even that its through the exception.

This is Exception that i got.

Leadtools.RasterException: Not able to open file

at Leadtools.RasterException.CheckErrorCode(Int32 code)

at Leadtools.Codecs.RasterCodecs.SaveOnePage(Int32 page, SaveParams saveParams)

at Leadtools.Codecs.RasterCodecs.DoSave(SaveParams saveParams)

at Leadtools.Codecs.RasterCodecs.Save(RasterImage image, String fileName, RasterImageFormat format, Int32 bitsPerPixel)

at ImageLibrary.SaveLeadImage(String OriginalFileName, RasterImage srcImage, String savePath) in D:\ImageLibrary.cs:line 463

Looking for your reply.

Parames

 

 
#4 Posted : Friday, June 27, 2008 5:59:33 AM(UTC)

jigar  
Guest

Groups: Guests
Posts: 3,034

Was thanked: 1 time(s) in 1 post(s)

Try the code below and see if you get an error.  For the file name in the OpenWrite() method, specify the exact same file as you did with your Save() method, so we know if there are some file access problems.
 
MemoryStream ms = new Memory Stream();
codecs.Save(ms, ... <rest of the parameters>);

FileStream fs = File.OpenWrite("your file name here");
fs.Write(ms.GetBuffer(), 0, ms.Length);
fs.Close();

 
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2020, Yet Another Forum.NET
This page was generated in 0.203 seconds.