Update Layout of Pages in Word Document using C# .NET and Handle System.InvalidOperationException

Hi, please find attached a sample document. Her is some code to get the exception:
[…]
mpg_Doc->UpdatePageLayout();
[…]
Eine Ausnahme (erste Chance) des Typs “System.InvalidOperationException” ist in mscorlib.dll aufgetreten.
Zusätzliche Informationen: Der Stapel ist leer.
[…]
mpg_Doc->Save(sTargetFilePath,Words::SaveFormat::Pdf);
[…]
Eine Ausnahme (erste Chance) des Typs “System.InvalidOperationException” ist in mscorlib.dll aufgetreten.
Zusätzliche Informationen: Der Stapel ist leer.
We’re using Aspose.Words 9.0.0.0. Thanks and regards.

Hi

Thanks for your inquiry. I cannot reproduce the problem with the latest version of Aspose.Words (9.4.0). You can download the latest version from here:

Best regards,