yesIf 'y1'in the drop down list is selected you want the following to happen:
1) display message box
2) Delete Cell I2 from the 'Converter' tab
Is that It?
it can either be Y1,Y2 or Y3 -display the message y1 selected or y2 selected or y3 and delete cell i2 in every selection
If 'y1'in the drop down list is selected you want the following to happen:
1) display message box
2) Delete Cell I2 from the 'Converter' tab
Is that It?
Private Sub Worksheet_Change(ByVal Target As Range)
'
If Not Intersect(Target, Range("C1")) Is Nothing And Target.Cells.Count = 1 Then
Select Case Target
Case Is = "y1"
MsgBox "Please select Y1" & "(Same year)" & " " & "in CONVERTER TAB Cell H2 and delete values" & " " & "(if any) from Cell I2" & " " & "(Import)"
Sheets("Converter").Range("I2").ClearContents
Case Is = "y2"
MsgBox "Please select Y2" & "(Same year)" & " " & "in CONVERTER TAB Cell H2 and delete values" & " " & "(if any) from Cell I2" & " " & "(Import)"
Sheets("Converter").Range("I2").ClearContents
Case Is = "y3"
MsgBox "Please select Y3" & "(Same year)" & " " & "in CONVERTER TAB Cell H2 and delete values" & " " & "(if any) from Cell I2" & " " & "(Import)"
Sheets("Converter").Range("I2").ClearContents
End Select
End If
End Sub
works perfectly fine....thank you so much for the supportOk I leave it to you to set the message box to what you want it to say for each selection in the the drop down list. I have added the code to each selection to delete 'I2'.
VBA Code:Private Sub Worksheet_Change(ByVal Target As Range) ' If Not Intersect(Target, Range("C1")) Is Nothing And Target.Cells.Count = 1 Then Select Case Target Case Is = "y1" MsgBox "Please select Y1" & "(Same year)" & " " & "in CONVERTER TAB Cell H2 and delete values" & " " & "(if any) from Cell I2" & " " & "(Import)" Sheets("Converter").Range("I2").ClearContents Case Is = "y2" MsgBox "Please select Y2" & "(Same year)" & " " & "in CONVERTER TAB Cell H2 and delete values" & " " & "(if any) from Cell I2" & " " & "(Import)" Sheets("Converter").Range("I2").ClearContents Case Is = "y3" MsgBox "Please select Y3" & "(Same year)" & " " & "in CONVERTER TAB Cell H2 and delete values" & " " & "(if any) from Cell I2" & " " & "(Import)" Sheets("Converter").Range("I2").ClearContents End Select End If End Sub
Make sure the 'Converter' sheet name is spelled correctly in the code.
Lemme know how that works.