G Guest Jan 11, 2006 #1 I want to create a command button that will filter specifice product. Could you please give me sample macro that filter data. Thanks.
I want to create a command button that will filter specifice product. Could you please give me sample macro that filter data. Thanks.
G Guest Jan 11, 2006 #2 Sub test() ' ' test Macro ' Macro recorded 11/01/2006 by Kevin M ' ' Columns("Your range of data").Select Selection.AutoFilter Selection.AutoFilter Field:=1, Criteria1:="your filter criteria" End Sub All this does is invoke autofilter and then selects a range for the user. HTH Kevin M
Sub test() ' ' test Macro ' Macro recorded 11/01/2006 by Kevin M ' ' Columns("Your range of data").Select Selection.AutoFilter Selection.AutoFilter Field:=1, Criteria1:="your filter criteria" End Sub All this does is invoke autofilter and then selects a range for the user. HTH Kevin M