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

Free Support Forum - aspose.com

Table Withing a Table Parent-Child

Is is possible to have a table within a table, where colum values from the parent table exist before and after the child table as shown below? It seems when I placed column values on two rows before and one after the child table I got the error "TableStart and TableEnd should be in the same section, same table row or same table cell."

ParentTableStart
Row1: Value Value
Row2: Value
ChildTableStart
Row1 Value
Row 2 Value
ChildTableEnd
Partent Value 3
ParentTableEnd

Hello

Thanks for your request. Aspose.Words allows nesting mail merge regions inside each other in a document to reflect the way the data is nested and this allows you to easily populate a document with hierarchical data.

Please see the following link to learn how to work with nested regions:

http://www.aspose.com/documentation/.net-components/aspose.words-for-.net/howto-use-nested-mail-merge-regions.html

Best regards,

I did see that link before posting this. The issue is from word document template. In template I have table and tags "TableStart:ParentTable" and "TableEnd:ParentTable" span across multiple rows, then I am getting error. I attached sample tempalte document what I am tyring to do.

Hello

Thank you for additional information. The mail merge region opening and closing tag (e.g. TableStart:Order, TableEnd:Order) both need to appear in the same row or cell. For example, if you start a merge region in a cell of a table, you must end the merge region in the same row as the first cell. It is by design.

Best regards,

Thank you for the information. I have quick question not related this though.

If I use part of the word document as a seperate template, to repeatedly fll this template in a loop, then can we merge this template with another document with out a page break.

Hi there,

Thanks for your inquiry.

Just incase you misunderstood, the current region structure you were using was invalid, however with some modifications to your template you can still get the layout you are looking for to work. Please see the attached template which demonstrates how to structure the nested regions so your template will work correctly.

Also, sure you can join documents without any page break, in this case you will just need to append them with "SectionStart.Continuous". Please see the article here for details.

If we can help you with anything else, please feel free to ask.

Thanks,