This project has moved and is read-only. For the latest updates, please go here.

How to Set print Area

Feb 3, 2011 at 7:01 AM

Hello Sir,

            Im Using EPPlus for creating Excel in c#..i created the Excel file Successfully,But i dnt know how to set the Print Area in that excel, can Any one help me to solve this problem.


Feb 3, 2011 at 3:20 PM


Use the Worksheet.PrinterSettings.PrintArea property. Something like..


Feb 6, 2011 at 12:53 PM
Edited Feb 7, 2011 at 11:09 AM

Thanks for ur Kind Help..

                In that Excel file how to set the Row header in all pages .I tried many things but i dnt get the correct format.

               Im using this statement..

              ws.PrinterSettings.RepeatRows.Address = "6:6";

              im getting this error  "Object reference not to set an instance of an object"...


Feb 7, 2011 at 6:53 PM

Hi again,