Karlbirger
Board Regular
- Joined
- Sep 21, 2011
- Messages
- 68
Hi guys,
I've been trying to configure my formula in Worksheet_Change to only run when targeted cells are being changed (by using Target). I don't get it to work properly.
A cell value is supposed to change in column AK when the equivalent cell in column H is changed.
Please se my formula below.
Anyone used to work with Worksheet_Change Target who can see how I use Target wrong?
Regards
KB
I've been trying to configure my formula in Worksheet_Change to only run when targeted cells are being changed (by using Target). I don't get it to work properly.
A cell value is supposed to change in column AK when the equivalent cell in column H is changed.
Please se my formula below.
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = "H" Then
Dim LastRow As Long
Dim Cell As Range
LastRow = Range("H" & Rows.Count).End(xlUp).Row
For Each Cell In Range("H6:H" & LastRow)
If Cell.Value = "Yes" Then
Range("AK" & Cell.Row).Value = "1.00"
Else
End If
Next Cell
End If
End Sub
Anyone used to work with Worksheet_Change Target who can see how I use Target wrong?
Regards
KB