Hi
I am passing a string to a string variable (which is correctly declared as a STRING) and the strings I am passing are the names of ranges in a worksheet. I would like to use the variable name in the data validation method...
I have tried several variations on this; putting it in speech marks, brackets, semicolon etc, but I just cant get it to work. Any help would be greatly appreciated.
I am passing a string to a string variable (which is correctly declared as a STRING) and the strings I am passing are the names of ranges in a worksheet. I would like to use the variable name in the data validation method...
Rich (BB code):
With Selection.Validation
.Delete
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
xlBetween, Formula1:= VARIABLE NAME WOULD GO HERE
.IgnoreBlank = True
.InCellDropdown = True
End With
I have tried several variations on this; putting it in speech marks, brackets, semicolon etc, but I just cant get it to work. Any help would be greatly appreciated.