createStyledTable
public static void createStyledTable()
throws Exception
Create a table with some row and column styling. I "manually" add the
style name to the table, but don't check to see if the style actually
exists in the document. Since I'm creating it from scratch, it obviously
won't exist. When opened in MS Word, the table style becomes "Normal".
I manually set alternating row colors. This could be done using Themes,
but that's left as an exercise for the reader. The cells in the last
column of the table have 10pt. "Courier" font.
I make no claims that this is the "right" way to do it, but it worked
for me. Given the scarcity of XWPF examples, I thought this may prove
instructive and give you ideas for your own solutions.
- Throws:
Exception