ManUBlueJay
Active Member
- Joined
- Aug 30, 2012
- Messages
- 320
- Office Version
- 365
- Platform
- Windows
I have an entry Form where one cell will either have a drop down list or free flow with a duplicate check
Drop Down list is named as Range1 I use this VBA code and it works as intended
F1 is also needs to be freeform when another criteria is met.
I would like a DupCheck.
When I use this formula in F1 as a custom data validation it works =COUNTIF(DS_ProjectNumsRange,F1)<1
When I name this Formula as Range2 and use =Range2 in F1 as a custom validation it no longer functions.
Question 1 is why?
Question 2 if Question 1 is a bug in Excel how do I enter the formula =COUNTIF(DS_ProjectNumsRange,F1)<1 in F1 using VBA.
Prefered solution would be using the formula
Drop Down list is named as Range1 I use this VBA code and it works as intended
VBA Code:
With Range("F1").Validation
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
xlBetween, Formula1:="=Range1l"
.IgnoreBlank = True
.InCellDropdown = True
End With
F1 is also needs to be freeform when another criteria is met.
I would like a DupCheck.
When I use this formula in F1 as a custom data validation it works =COUNTIF(DS_ProjectNumsRange,F1)<1
When I name this Formula as Range2 and use =Range2 in F1 as a custom validation it no longer functions.
Question 1 is why?
Question 2 if Question 1 is a bug in Excel how do I enter the formula =COUNTIF(DS_ProjectNumsRange,F1)<1 in F1 using VBA.
Prefered solution would be using the formula