Set AutoFilter in Excel with VBA -
Can anyone explain that the first "Autofilter" statement in the code below is "Autofilter Mad of Range Class" Fail "Why Does 2010?
ActiveSheet.AutoFilterMode = False shtUSR.Range ("A1"). Choose ActiveSheet.Range ("A1"). AutoFilter field: = 1, Sceneable dropdown: = True ActiveSheet.Range ("B1"). Autofilter field: = 2, widgetDowndown: = TruCThese.OutofilterMode = true
I think That I got it!
Obviously, the auto filter fails if it can not get any data in the range. Try adding value to A1 and B1 cells (and also remove the ActiveSheet.AutoFilterMode = True
line) For 'normal usage', to be safe, you need to have data within range You will need to do a search or test.
1 for good Q though.
Comments
Post a Comment