I have a C# application that is using the NPOI library version 2.3.0.0. I want to print an excel document with the default print dialog settings pager size set to Legal Paper.
I've done the following in code xlsx is an IWorkbook and sheet is ISheet.
var sheet = xlsx.CreateSheet("Statement");
sheet.PrintSetup.PaperSize = (short)PaperSize.US_Legal;
I expect when I go to Print that the Settings show as Legal and not as Custom Paper Size. But this isn't the case. Can someone fill me in on why I'm not getting the Legal Paper size to be set?