Hi,
I need to add an if statement to a code already up and running but I'm pretty new to vba
below the code
Option Explicit
Private Sub WorkSheet_Change(ByVal Target As Range)
'Clear Range R and restore to values in Range P
If (Target.Address = "$P$6") Then
Range("$R$8:$R$65").ClearContents
Range("$R$8:$R$65").Value = Range("$P$8:$P$65").Value
'If range P changes, Change corresponding cell in Range R.
ElseIf Not Intersect(Target, Range("$P$8:$P$65")) Is Nothing Then 'Double negative = positive
If LCase(Target.Value) = "Apply same assumptions across currencies / asset classes" Or LCase(Target.Value) = "Apply different assumptions across currencies / asset classes" Then
Target.Offset(0, 2).Value = Target.Value
ElseIf LCase(Target.Value) = "please select" Then
Target.Offset(0, 2).Value = ""
End If
End If
End Sub
What I would need to add is: if P6="Apply same assumptions across currencies / asset classes" then whatever value I put in R8-R65 copy that into R69-R126, otherwise "please select".
it's worth noting that in R69-R126 I have a drop down menu (the same as in R8-R65)
I would appreciate any help on this!!
Daniele
Bookmarks