Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
'Plan Rejected
If Target.Column = 12 Then
ActiveSheet.Unprotect Password:="test"
Target.Offset(0, -6) = 0
'Target.Offset(0, 1) = Date + Time
Target = "þ"
'Range("b" & Target.Row & ":bz" & Target.Row).Locked = True
ActiveSheet.Protect Password:="test"
End If
I am confused by the following code. The two rows that you see as commented out do not run when they are uncommented. If I switch the two target.offset codes the first one always runs and the second one does not. The locked range used to work until I added the second offset and now it does not run even if bad code gets commented out.
'Plan Rejected
If Target.Column = 12 Then
ActiveSheet.Unprotect Password:="test"
Target.Offset(0, -6) = 0
'Target.Offset(0, 1) = Date + Time
Target = "þ"
'Range("b" & Target.Row & ":bz" & Target.Row).Locked = True
ActiveSheet.Protect Password:="test"
End If
I am confused by the following code. The two rows that you see as commented out do not run when they are uncommented. If I switch the two target.offset codes the first one always runs and the second one does not. The locked range used to work until I added the second offset and now it does not run even if bad code gets commented out.