kiwikiki718
Board Regular
- Joined
- Apr 7, 2017
- Messages
- 80
- Office Version
- 365
- Platform
- Windows
I created a VBA code that will prevent users from selecting duplicate data from a drop down list in column C of my excel spreadsheet, however I want users to be able to select "Other" in multiple fields without receiving an error.
Here is the code that I have written but need to show how to exclude the selection "Other".
Private Sub worksheet_change(ByVal Target As Range)
If Application.CountIf(Range("C:C"), Target) > 1 Then
MsgBox "Duplate Custom field Selected!", vbCritical, "Remove Data"
Target.Value = ""
End If
End Sub
thank you in advance
Here is the code that I have written but need to show how to exclude the selection "Other".
Private Sub worksheet_change(ByVal Target As Range)
If Application.CountIf(Range("C:C"), Target) > 1 Then
MsgBox "Duplate Custom field Selected!", vbCritical, "Remove Data"
Target.Value = ""
End If
End Sub
thank you in advance