NativeExcel for .Net Developer's Reference

IPageSetup.PrintGridLines Property

Gets or sets a value that indicates whether the cell gridlines are printed on the page.

[Visual Basic]
Property PrintGridLines As Boolean
[C#]
bool PrintGridLines { get; set; }
[C++]
__property bool get_PrintGridLines();
__property void set_PrintGridLines(bool );
[JScript]
function get PrintGridLines() : bool
function set PrintGridLines(bool);

Property Value

True if cell gridlines are printed on the page.

Example

This example prints cell gridlines when sheet one is printed.

[C#]
book.Worksheets[1].PageSetup.PrintGridLines = true;
[Visual Basic]
book.Worksheets(1).PageSetup.PrintGridLines = True
[C++]
book->Worksheets->Item[1]->PageSetup->PrintGridLines = true;

See Also

IPageSetup Interface | NativeExcel Namespace | PageSetup Property