Hi All.
I have an Excel file where users can select from various dropdown lists (using data validation)
I have year and month drop downs in cells F12 (Month) and F13 (Year) and on a separate tab I have a list of Year and Month combinations for which we do not have rates.
I have entered a vlookup (G13) to check for the date combination and return "1" if it is found - I would like a Massage Box to pop up if the date is found in this list ie if the vlookup returns "1"
I have managed to get the code below to work but only when "1" is hard typed into the cell - it doesn't work when the formula result = 1.
Does anyone have any idea how I can get it to work from the formula?
Much appreciated!
I have an Excel file where users can select from various dropdown lists (using data validation)
I have year and month drop downs in cells F12 (Month) and F13 (Year) and on a separate tab I have a list of Year and Month combinations for which we do not have rates.
I have entered a vlookup (G13) to check for the date combination and return "1" if it is found - I would like a Massage Box to pop up if the date is found in this list ie if the vlookup returns "1"
I have managed to get the code below to work but only when "1" is hard typed into the cell - it doesn't work when the formula result = 1.
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Dim A As Range
Set A = Range("G13")
If Intersect(Target, A) Is Nothing Then Exit Sub
If Target.Value = 1 Then
MsgBox "Rates for this broadcast period are not yet available"
End If
End Sub
Does anyone have any idea how I can get it to work from the formula?
Much appreciated!