ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Excel VBA Code to hide dark black selector box? (https://www.excelbanter.com/excel-programming/328976-excel-vba-code-hide-dark-black-selector-box.html)

Scott B

Excel VBA Code to hide dark black selector box?
 
Is there any VBA Code to hide the dark box that indicates the currently
selected cell? My sheet I have has no need for this to be seen. Hiding it
would be nice. TIA!

Scott



Dave Peterson[_5_]

Excel VBA Code to hide dark black selector box?
 
If you protect the sheet in code, you can make it so the user cannot even select
a cell.

Option Explicit
Sub auto_open()
Dim wks As Worksheet
Set wks = Worksheets("sheet1")
With wks
.Protect Password:="hi"
.EnableSelection = xlNoSelection
End With
End Sub

Or maybe you could just select a cell that's way off the screen (IV65536?).
Scott B wrote:

Is there any VBA Code to hide the dark box that indicates the currently
selected cell? My sheet I have has no need for this to be seen. Hiding it
would be nice. TIA!

Scott


--

Dave Peterson


All times are GMT +1. The time now is 12:08 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com