Quote Originally Posted by GideonE View Post
Thank you for that tip Si

However I have tried :

Code:
xlWorkSheet.DisplayGridlines = False
I get the following error when I run (not in the editing mode of Visual studio)

System.MissingMemberException: 'Public member 'DisplayGridlines' on type 'Worksheet' not found.'


I also tried :

Code:
xlWorkSheet.Activate()
xlWorkSheet.DisplayGridlines = False
I get the same error message.

Regards
I think you’ll find DisplayGridlines is a member of Range, rather than WorkSheet.Try this…

Code:
Dim x as Range = Worksheets("Sheet name").Cells
x.DisplayGridlines = False