Using Aspose.Words .NET v20.12.0
The following code produces an OutOfMemoryException using a 60+MB text file:
LoadOptions options = new LoadOptions();
options.LoadFormat = LoadFormat.Text;
Document doc = new Document(filePath, options);
doc.Save(OutputFilePath, new TxtSaveOptions
{
MemoryOptimization = true
});
Here is the stack: (weird symbols in source, see attached screenshot)
at System.Text.StringBuilder.ToString()
at . ( )
at . ( )
at Aspose.Words.Document.( )
at Aspose.Words.Document.(Stream , String , SaveOptions )
at Aspose.Words.Document.Save(String fileName, SaveOptions saveOptions)
image.png (5.8 KB)