You could prevent them from being selected: use this event: copy the coe,
right click on the worksheet tab, select "View Code" and paste the code in
the window that appears.
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
Application.EnableEvents = False
Target.SpecialCells(xlCellTypeVisible).Select
Application.EnableEvents = True
End Sub
Yes but I am unable to type if I would like to in a single cell. No matter
what you do it selects everything. Is there a way to retain the regular
spreadsheet functionality when filtering? Is there a setting in options that
may differ from spreadsheet to spreadsheet?
But given your described symptoms, try changing it to:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
Application.EnableEvents = False
If Target.Cells.Count > 1 Then _
Target.SpecialCells(xlCellTypeVisible).Select
Application.EnableEvents = True
End Sub
But given your described symptoms, try changing it to:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
Application.EnableEvents = False
If Target.Cells.Count > 1 Then _
Target.SpecialCells(xlCellTypeVisible).Select
Application.EnableEvents = True
End Sub
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.