Hi Guys,
I am trying to edit a worksheet so that when you select certain values in cell D5 it will give you a dropdown box in E5 and if you select other values then it will simply give you the value "N/A"
Through some googling it looked like the only way to do this was with a macro and what I have is here:
Private Sub Worksheet_Change(ByVal Target As Range)
Application.ScreenUpdating = False
ActiveSheet.DisplayPageBreaks = False
If Not Intersect(Target, Range("D5:D500")) Is Nothing Then
Dim j As Integer
For j = 5 To 500
If Cells(j, 5) = "" Then
If Cells(j, 4) = "ACB" Or Cells(j, 4) = "MCB" Or Cells(j, 4) = "MCCB" Or Cells(j, 4) = "MPCB" Then
Cells(j, 5).Activate
With ActiveCell.Validation
.Add xlValidateList, xlValidAlertStop, xlBetween, "=$V$5:$V$7"
.InCellDropdown = True
End With
Else
Cells(j, 5) = "N/A"
End If
End If
Next j
End If
End Sub
However when I run this it does absolutely nothing..........
Any help would be greatly appreciated!
I have attached the sheet if its helpful and it is on the worksheet "Circuit Breakers"
Thanks!
Tom
Bookmarks