OutOfMemoryException: export to spreadsheet with SAX approach

Home Forums Open-Xml-Sdk OutOfMemoryException: export to spreadsheet with SAX approach

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #3441
    Eric White
    Keymaster

    Hi Krzysztof,

    There are lots of factors that can impact memory usage. Also OutOfMemoryException sometimes does not mean that the program is out of memory – it can mean that the memory is too fragmented to allocate the desired amount of memory.

    The first thing that I recommend that you do is to build in 64-bit mode. I have encountered situations where the Open-Xml-Sdk ran out of memory in 32-bit mode, but did not in 64-bit mode.

    Certainly, the memory usage profile for 2.6 will be different from 2.5. Version 2.6 is based on System.IO.Compression, which will alter the pattern of memory usage. Version 2.5 was based on a weird, internal implementation of the ZIP file format, and I don’t know the details of the impact of these two libraries on memory usage. I am not surprised that they are different.

    Unfortunately, I have been pulled from that project. I am no longer maintaining the Open-Xml-Sdk.

    I suggest that you try with 64 bit mode. If that does not fix your issue, then I suggest that you create an issue on GitHub for this.

    Cheers, Eric

    #3446
    Krzysztof D.
    Participant

    Hi Eric,

    yep, it’s thrown from the IO* module, not directly from OpenXML – just treated it as a whole.
    will give a try in free time to check it again.
    thank you for info and suggestions.

    Cheers,
    Krzysztof

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.