toggle grid

  • Thread starter Thread starter Todd
  • Start date Start date
T

Todd

Hi,

I am wondering if I can put a button on a worksheet to
utilize the toggle grid function? I am turning off the
grid lines all the time in one worksheet and I move from
one computer to another so adding to the toolbar is a
pain.

TIA
 
Todd

Try....

Sub Gridlines()
ActiveWindow.DisplayGridlines = Not ActiveWindow.DisplayGridlines
End Sub
--
XL2002
Regards

William
(e-mail address removed)

| Hi,
|
| I am wondering if I can put a button on a worksheet to
| utilize the toggle grid function? I am turning off the
| grid lines all the time in one worksheet and I move from
| one computer to another so adding to the toolbar is a
| pain.
|
| TIA
 
Try Tools|customize|commands Tab|Forms category. It's near the bottom (well,
for xl2002 anyway)

(I like this button, too!)
 
Todd

Copy/paste William's macro your workbook then from the Forms Toolbar place a
button on the worksheet and assign the macro to that button.

The macro and the button will travel with the workbook and no need to
customize any Toolbars.

Gord Dibben Excel MVP XL2002
 
Thanks very much. I put the button in the workbook and it is wonderful!

Thanks again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top