Hi guys,
I use code when double click the cell will insert new row with the same formatting & formulas , but I want preventing user to double click on any cell contains formuals without using protection for some cells .
in my case I don't want the user double click in any cells in columns A,E contains formulas. I no know if could be by vba
this is the code.
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
With ActiveCell.EntireRow
.Copy
.Offset(1).Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
On Error Resume Next
.Offset(1).SpecialCells(xlCellTypeConstants).Value = ""
Application.CutCopyMode = False
On Error GoTo 0
End With
End Sub