Can I set auto-width on an Open XML SDK-generated spreadsheet without calculating the individual wid
Posted
by ccornet
on Stack Overflow
See other posts from Stack Overflow
or by ccornet
Published on 2010-05-03T18:11:55Z
Indexed on
2010/05/03
18:18 UTC
Read the original article
Hit count: 1116
I'm working on creating an Excel file from a large set of data by using the Open XML SDK. I've finally managed to get a functional Columns node, which specifies all of the columns which will actually be used in the file. There is a "BestFit" property that can be set to true, but this apparently does not do anything. Is there a way to automatically set these columns to "best fit", so that when someone opens this file, they're already sized to the correct amount? Or am I forced to calculate how wide each column should be in advance, and set this in the code?
© Stack Overflow or respective owner