I am building a project that will export information to a Word 2007 file and would like to use Open XML SDK 2.0 (vs Office.Interop). From what I've read the way you merge data into word is by using XSLT, but I'm brand new to XSLT and have a question about
its capabilities.
Can I take a string[] of 9 names and build a 3x3 table? Then when I only have 4 names build a 2x3 table? Then when I only have 2 names build a 1x3 table?
Any references to examples of something like or documentation would be helpful.
Member
20 Points
294 Posts
XSLT to create a 2x3 table from a string[]
Oct 21, 2013 04:10 PM|jhoop2002|LINK
I am building a project that will export information to a Word 2007 file and would like to use Open XML SDK 2.0 (vs Office.Interop). From what I've read the way you merge data into word is by using XSLT, but I'm brand new to XSLT and have a question about its capabilities.
Can I take a string[] of 9 names and build a 3x3 table? Then when I only have 4 names build a 2x3 table? Then when I only have 2 names build a 1x3 table?
Any references to examples of something like or documentation would be helpful.
All-Star
15648 Points
2151 Posts
Re: XSLT to create a 2x3 table from a string[]
Oct 22, 2013 07:47 AM|Happy Chen - MSFT|LINK
hi jhoop2002,
I would suggest that you read this reference below:
Building HTML Tables with XSL
http://www.computorcompanion.com/LPMArticle.asp?ID=202
XML: Create HTML table using XSLT
http://www.bewebmaster.com/80.php
Generate Word Documents Using Open XML SDK 2.0 for Microsoft Office
http://www.aspnetwiki.com/implementing-open-xml-sdk-2-0-for-microsoft-office