Free Support Forum -

Textcolumns count changes not working

I'm trying to write some text, make 3 columns, write text in each, the make 1 column and continue writing. It works fine until I try changing back to 1 column. It stays at 3. How is this done?

Currently I'm doing a SectionBreakContinuous, change to 3 columns, another break, then back to 1.

Thank you for reporting. There is indeed a bug in TextColumns.SetCount method. It fails when setting count lesser than current.

I have logged this problem to our defect base as Issue #870. We will fix this in the next release which will be in approximately 3 weeks from now.

I will also check if the workaround is possible.

A work around would be great. The application that's using this needs to go live in the next couple weeks. Probably before the next release.

I accidently posted instead of replying the first time.

I have the same problem, but I have found a workaround:

When creating the document I use a "template"-document (created with MS Word) with the necessary types of sections and columns in each section. So I have not to change the no of columns in code. I just move to the section. Perhaps you need different templates with different predefined sections.

Maybe it helps you too!

The issue with “TextColumns.SetCount does not work when setting count lesser than current” is fixed in Aspose.Words 3.6 which is now available for download.