We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Validation on Space After

Hi Aspose Team,

I’ve found a defect with setting values that are not available in Word. Code looks like follows:

        var output = new Document();
        output.EnsureMinimum();

        var builder = new DocumentBuilder(output);
        
        builder.MoveToHeaderFooter(HeaderFooterType.FooterPrimary);
        builder.Write("Text In Footer.");
        builder.CurrentParagraph.ParagraphFormat.SpaceAfterAuto = false;
        builder.CurrentParagraph.ParagraphFormat.SpaceAfter = -14;

        builder.Document.Save("Output//Results.docx");

The values available in Word are in range -1pt to 1584pt, setting -14 for whatever reason sets it to 3262.65.

Could you please fix it? I’d expect validation and exception thrown on setting value that is out of available range, same as it’s done for few other properties.

Thanks,
Mateusz

@acturisaspose

We have tested the scenario and have managed to reproduce the same issue at our side. For the sake of correction, we have logged this problem in our issue tracking system as WORDSNET-19480. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

Has this issue been fixed? The ticket status = closed…

@acturisaspose

We have good news for you i.e. your issue has now been resolved. Please use the latest version of Aspose.Words for .NET 19.12.

The issues you have found earlier (filed as WORDSNET-19480) have been fixed in this Aspose.Words for .NET 19.12 update and this Aspose.Words for Java 19.12 update.