Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with memory usage #6

Open
Iceblooms opened this issue Dec 20, 2023 · 0 comments
Open

Issue with memory usage #6

Iceblooms opened this issue Dec 20, 2023 · 0 comments

Comments

@Iceblooms
Copy link

Iceblooms commented Dec 20, 2023

Hi there!✌ Sorry, if that isn't right place for this, but i was meet an issue while working with following class:

  • ConvertToPDF method of Syncfusion.DocToPDFConverter.DocToPDFConverter (with WordDocument signature)

When that method are executing application consume huge amount of RAM, and when RAM is over - starts using virtual memory (swap). After conversion ends, memory doesn't release and this pretty sad.

Releasing resources it's main problem in this case, but it would be great to add the feature to interrupt the conversion may be, because sometimes that takes are really long time.


Usage in code:

~~~
using (var documentMemoryStream = new MemoryStream(source.Data))
{
    using (var wordDocument = new WordDocument(documentMemoryStream, FormatType.Automatic))
    {
        wordDocument.ChartToImageConverter = new ChartToImageConverter();

        using (var converter = new DocToPDFConverter())
        {
            using (var pdfDocument = converter.ConvertToPDF(wordDocument))
            {
                pdfDocument.EnableMemoryOptimization = true;
                pdfDocument.Save(resultStream);
            }
        }
    }
}
~~~

Found at Syncfusion.DocToPDFConverter.WinForms v. 24.1.41
Reproduces with this file:
Notes for English learning.docx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant