Exceptions on loading valid Excel file - every time

Last post 02-13-2012, 3:48 AM by aspose.notifier. 55 replies.
Page 1 of 4 (56 items)   1 2 3 4 Next >
Sort Posts: Previous Next
  •  11-03-2011, 5:04 PM 340055

    Exceptions on loading valid Excel file - every time .NET

    Hi,

    In the C#/.NET component, upon calling:

    new Workbook(fileName);

    two exceptions are being thrown and caught every time. These are "Could not read block - no data!" and after that, "Cannot read that as a Zip file". I have my debugger set to break on any exceptions so I'm aware of these occurring even though they're being caught.

    Even though they're being caught, throwing and catching exceptions is very slow (compared with other operations) and it should be avoided. Paying this performance cost every single time a file is loaded is not very good design from a performance standpoint (as well as the annoyance of having the debugger break!)

    I hope it will be fixed soon as we're looking to evaluate an Excel interoperability library and are strongly considering Aspose.
    Filed under: Design;Exception
     
  •  11-03-2011, 8:31 PM 340069 in reply to 340055

    Re: Exceptions on loading valid Excel file - every time

    Hi,

    Please post your template file, we will check it soon.


    Simon Zhao
    Developer
    Aspose Nanjing Team
    Contact Us
     
  •  11-27-2011, 6:47 AM 344831 in reply to 340055

    Re: Exceptions on loading valid Excel file - every time .NET

    I have met the exact same problem as MgSam's and have not got a answer up to now. Looking forward to see the solution to this problem as soon as possible.
     
  •  11-28-2011, 10:54 AM 345136 in reply to 340069

    Re: Exceptions on loading valid Excel file - every time

    var workBook = new Workbook(filePath);
    

    This throws and catches exceptions each time its invoked. I've also found that

    workBook.Save(filePath)

    is throwing and catching an exception each time its invoked.


    This really needs to be addressed. It screws up debugging and is needlessly inefficient.
     
  •  11-28-2011, 12:06 PM 345160 in reply to 345136

    Re: Exceptions on loading valid Excel file - every time

    Hi,

    Please attach your template Excel file. If possible, please create a sample console application, zip it and post it here to reproduce the issue on our end with template file.

    We will check your issue soon.

    Thank you.

    Amjad Sahi
    Support Developer,
    Aspose Sialkot Team
    Contact Us
     
  •  11-28-2011, 12:53 PM 345172 in reply to 345160

    Re: Exceptions on loading valid Excel file - every time .NET

    Attachment: Present (inaccessible)
    I've included a project that does nothing other than instantiate a Workbook object and then tries to save it. If you run it with the VS debugger set to break on all exceptions, you will see the issue. It only occurs for xls files, not xlsx, from what I can tell.
     
  •  11-28-2011, 1:40 PM 345181 in reply to 345172

    Re: Exceptions on loading valid Excel file - every time

    Attachment: Present (inaccessible)
    Hi,

    I have tested your file with the latest version: Aspose.Cells for .NET v7.0.3.2 and it is working fine.

    Please see the code below and the output xls file.

    C#
    string path = @"F:\Shak-Data-RW\Downloads\AposeCellsProblem\Test.xls";
    Workbook wb = new Workbook(path);
    wb.Save(path + ".out.xls");


    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Developer
    Aspose Sialkot Team
    Contact Us
    Aspose - The .NET and Java Component Publisher

    Keep in touch! We're on Twitter and Facebook
     
  •  11-28-2011, 2:34 PM 345192 in reply to 345181

    Re: Exceptions on loading valid Excel file - every time

    I am not able to get the DLL you linked to work at all. It must be built for your specific machine or something else is wrong.

    Was this issue actually known about and fixed in a newer build, or you just were not able to replicate the issue?
     
  •  11-28-2011, 2:45 PM 345195 in reply to 345192

    Re: Exceptions on loading valid Excel file - every time

    Hi,

    What is the .NET framework version of your System? Are you using .NET framework ClientProfile? In this case, you will need a different dll and not this one.

    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Developer
    Aspose Sialkot Team
    Contact Us
    Aspose - The .NET and Java Component Publisher

    Keep in touch! We're on Twitter and Facebook
     
  •  11-28-2011, 3:09 PM 345198 in reply to 345195

    Re: Exceptions on loading valid Excel file - every time

    I'm using Windows 7 64 bit. I did have the test project set to .NET 4.0 Client Profile but I changed it to .NET 4.0 based on your feedback so that I could test this DLL. However, the same exact exceptions still occur.

    They are handled exceptions. They are thrown and caught internally in Apose.Cells, every time. I known they are happening because my debugger is set to break whenever an exception is thrown. It doesn't affect the library from being usable, but it is a serious pain when debugging and its inefficient.

    Did you even try to reproduce the problem before telling me it is working fine?
     
  •  11-28-2011, 3:20 PM 345200 in reply to 345198

    Re: Exceptions on loading valid Excel file - every time

    Hi,

    Yes, I did test it as you can see the sample code and the output file attached by me. I was not able to reproduce the problem.

    It seems, you need ClientProfile dll. We will provide it to you asap.

    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Developer
    Aspose Sialkot Team
    Contact Us
    Aspose - The .NET and Java Component Publisher

    Keep in touch! We're on Twitter and Facebook
     
  •  11-29-2011, 11:57 AM 345449 in reply to 345200

    Re: Exceptions on loading valid Excel file - every time

    So is there a resolution?
     
  •  11-29-2011, 5:49 PM 345522 in reply to 345449

    Re: Exceptions on loading valid Excel file - every time

    Hi,

    Please try the client profile version of Aspose.Cells dll, which you will find in net3.5_ClientProfile folder and share your feedback with me.

    Please download the MSI installer that will create the above folders from this link: Aspose.Cells for .NET 7.0.3
    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Developer
    Aspose Sialkot Team
    Contact Us
    Aspose - The .NET and Java Component Publisher

    Keep in touch! We're on Twitter and Facebook
     
  •  11-30-2011, 8:11 AM 345783 in reply to 345522

    Re: Exceptions on loading valid Excel file - every time

    I tried this and the same exceptions are still thrown (and caught). I strongly suspect these exceptions have nothing to do with the framework version.

    Clearly, I am not the only one having this issue, as only a small subset of users of a product typically post on a forum and this thread has two people encountering it.

    Can you please try and project that I uploaded for you to test with and list every step you are taking to reproduce the problem? I'm not sure that you're understanding what the issue is.

    Here is the exception text again:

    new Workbook("myfile.xls"); - causes the following exceptions to be thrown and caught:

    ࣝ.დ occurred
      Message=Could not read block - no data!  (position 0x00000000)
      Source=Aspose.Cells
      StackTrace:
           at ࣝ.Ⴏ._Ⴟ(Stream ݞ, String Ⴠ)
      InnerException:

    ࣝ.Ⴎ occurred
      Message=Cannot read that as a ZipFile
      Source=Aspose.Cells
      StackTrace:
           at ࣝ.ვ.ᅻ(ვ ၧ)
      InnerException: ࣝ.დ
           Message=Could not read block - no data!  (position 0x00000000)
           Source=Aspose.Cells
           StackTrace:
                at ࣝ.Ⴏ._Ⴟ(Stream ݞ, String Ⴠ)
                at ࣝ.Ⴏ.Ⴞ(Stream ݞ)
                at ࣝ.ვ.ᅽ(Stream ݞ)
                at ࣝ.ვ.ᅻ(ვ ၧ)
           InnerException:

    workbook.Save("out.xls") - causes the following exception to be thrown and caught:

    System.ArgumentException occurred
      Message=Item has already been added. Key in dictionary: '0'  Key being added: '0'
      Source=mscorlib
      StackTrace:
           at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)
      InnerException:

     
  •  11-30-2011, 3:21 PM 345908 in reply to 345783

    Re: Exceptions on loading valid Excel file - every time

    Hi,

    Its strange, your issue is still unresolved.

    I have forwarded your thread to our development team. I have also logged this issue in our database. We will look into it and update you asap.

    This issue has been logged as CELLSNET-40141.

    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Developer
    Aspose Sialkot Team
    Contact Us
    Aspose - The .NET and Java Component Publisher

    Keep in touch! We're on Twitter and Facebook
     
Page 1 of 4 (56 items)   1 2 3 4 Next >
View as RSS news feed in XML