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

Free Support Forum - aspose.com

Edit RTF section types

I have RTF files that need to be processed: if there are \sectd sections and \posx parameter of this sections has value 0, section type should be changed from \sectd to \pard.

I was hoping to use Aspose.Words for this purpose since it’s already in my project but I can’t find any way to do so.
Is it even possible to to read position parameters and edit section types of RTF files with using Aspose.Words? Or may be there is any way to create new section of type \pard and copy text with formatting ( size, color, font ) from old one to new one?

Hi Kevin,
Thanks for your request. Aspose.Words does not allow working such a low level. Could you please describe what this change should do in your document? I mean what you would like to change or create in terms of document as whole?
Best regards,

I have software that generate RTF documents. If an RTF document contains \sectd sections, those sections end up outlined by a peculiar border when the file is opened in Word. The borders don’t appear if the file is printed, but do appear when viewing the file, which really annoys our managers.
So I think \sectd can be replaced with \pard in some cases when probability of loosing formatting is minimal. \pard doesn’t have such “problem”.

And I do realize it’s finding problems where there are none but can’t do much about it.

Thank you for additional information. But could you please attach your sample document here for testing? We will investigate it and provide you more information.
Best regards,

Thanks for reply.

Here is small generated file. If you’ll open it in Word ( in version 2010 at least ) and click on text, you’ll see section containing that text outlined by a peculiar border that used by Word to allow user to edit position of this section.

Thank you for additional information. As I can see there is Frame inside your document, currently, there is no API that allows working with text frames in Aspose.Words. We will consider adding such API in future. But you should note that text frames are obsolete and that is why this is not a very popular feature.
Best regards,

Well, thank you anyway.

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

This message was posted using Notification2Forum from Downloads module by aspose.notifier.