I am new to Excel and trying to solve this situation I am in.
>>> use code - tags <<<
The code above works fine except i want to add condition to it which i am not able to.
SO the condition is that if text in cell e16 is "keith" then above formulae is not required.IN that condition whatever is entered in above range should appear as it is. but if text in cell e16 is "jack" then above situation and formulae should come in action. Any advice and suggestion will be much appreciated here.
>>> use code - tags <<<
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Dim checkRange As Range
Set checkRange = Range("i22:i26")
If Not Application.Intersect(checkRange, Range(Target.Address)) Is Nothing Then
Application.EnableEvents = False
Application.ScreenUpdating = False
If Target.Text = "" Then
Target.Value = 0
Else:
Target.Value = (((((11758.74 * Target.Value - 88885.21) * Target.Value + 270177.93) * Target.Value - 413145.8) * Target.Value + 318417.95) * Target.Value - 99127.4536)
End If
Application.ScreenUpdating = True
Application.EnableEvents = True
End If
End Sub
The code above works fine except i want to add condition to it which i am not able to.
SO the condition is that if text in cell e16 is "keith" then above formulae is not required.IN that condition whatever is entered in above range should appear as it is. but if text in cell e16 is "jack" then above situation and formulae should come in action. Any advice and suggestion will be much appreciated here.
Last edited by a moderator: