I have the following code snippet somewhere in our application server code:
page.Layout.Blocks.RemoveAll(); page.Layout.BlackSeparators.RemoveAll(); page.Layout.VisualBlocks.RemoveAll(); page.ImageDocument.Modify(imageModification);
This code applies a crop modification to the image.
This code works fine on our production servers for over a year now, where SDK 10.0.8.109 is installed. However, on a new dev machine we've installed the latest version we have available, which is 10.0.11.98, and the exact same code is throwing the following exception:
System.Runtime.InteropServices.COMException (0x80004005): Cannot modify the page image. Remove all blocks and separators from the page layout and try again. at FREngine.IImageDocument.Modify(ImageModification Modification) at SaverrOCR.Program.simpleCrop(IFRPage page) at SaverrOCR.Program.recognizeImage(IFRPage page) at SaverrOCR.Program.ProcessTextImage() at SaverrOCR.Program.processWithEngine()
So something is obviously wrong here, we are doing what the error message suggests we should do, and the same code was previously working. Is it a bug in the engine? Or are we missing something else?