PrivateSub Worksheet_SelectionChange(ByVal Target As Range)
With Range("d7").Validation
.Delete
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Formula1:="1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70"
EndWith
End Sub
如代码:
Formula1 里面的值有70个,我用VBA导出后,直接下拉一条也不显示了
但是我换成
PrivateSub Worksheet_SelectionChange(ByVal Target As Range)
With Range("d7").Validation
.Delete
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Formula1:="1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19"
EndWith
End Sub
则可以支持下拉!请问这里是否能手动设置下下拉长度呢?求高手赐教!!!不胜感激!
噜噜哒