![]() |
Setting "DisplayGridlines" Programmatically
I am trying to set the "DisplayGridlines" property of a worksheet
programmatically. I am getting an error when using: Worksheets(<name of a valid sheet).DisplayGridlines = False The error is: Runtime error '438' Object doen't support this property or method How may I accomplish this task without error? Thanks and God bless. -- Dr. Doug Pruiett Good News Jail & Prison Ministry www.goodnewsjail.org |
Setting "DisplayGridlines" Programmatically
Doug,
Gridlines applies to the window object, so use Activewindow.Displaygridlines = False -- HTH RP (remove nothere from the email address if mailing direct) "Chaplain Doug" wrote in message ... I am trying to set the "DisplayGridlines" property of a worksheet programmatically. I am getting an error when using: Worksheets(<name of a valid sheet).DisplayGridlines = False The error is: Runtime error '438' Object doen't support this property or method How may I accomplish this task without error? Thanks and God bless. -- Dr. Doug Pruiett Good News Jail & Prison Ministry www.goodnewsjail.org |
Setting "DisplayGridlines" Programmatically
Hello,
Correct syntax is : ActiveWindow.DisplayGridlines = False Cesar Zapata |
Setting "DisplayGridlines" Programmatically
Just a hint, turn on the macro recorder and do it manually. Then your
question would be answered. -- Regards, Tom Ogilvy "Chaplain Doug" wrote in message ... I am trying to set the "DisplayGridlines" property of a worksheet programmatically. I am getting an error when using: Worksheets(<name of a valid sheet).DisplayGridlines = False The error is: Runtime error '438' Object doen't support this property or method How may I accomplish this task without error? Thanks and God bless. -- Dr. Doug Pruiett Good News Jail & Prison Ministry www.goodnewsjail.org |
All times are GMT +1. The time now is 01:47 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com