Filtro sin flechas de lista desplegable

t4373125

Board Regular
Joined
Jun 26, 2002
Messages
52
Me gustaria aplicar un filtro por codigo VBA y que no salgan las flechas de lista desplegable en todos los titulos.

Solo he logrado quitarla en la columna de la condicion:
Range("A1").AutoFilter 5, "Juan", VisibleDropDown:=False

Y de manera lenta y poco elegante en todas las demas:
Range("A1").AutoFilter 1, VisibleDropDown:=False
Range("A1").AutoFilter 2, VisibleDropDown:=False
Range("A1").AutoFilter 3, VisibleDropDown:=False
Range("A1").AutoFilter 4, VisibleDropDown:=False
Range("A1").AutoFilter 6, VisibleDropDown:=False

alguien sabe un método directo y rapido para quitar las flechas de los demas titulos de las columnas?

Gracias
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
La verdad no conozco un método más rápido, pero lo que se puede hacer es un ciclo, así:

<Pre>Sub T()
Dim i As Integer
For i = 1 To ActiveSheet.AutoFilter.Range.Columns.Count
If i = 1 Then
ActiveSheet.AutoFilter.Range.AutoFilter i, 5, VisibleDropDown:=False
Else
ActiveSheet.AutoFilter.Range.AutoFilter i, VisibleDropDown:=False
End If
Next i
End Sub</pre>

Aquí lo importante es la condición del i = 1, en la que si es cierto, pongo la condición del filtro, y si no, lo único que se hace es desaparecer la flecha.
 
Upvote 0

Forum statistics

Threads
1,214,911
Messages
6,122,196
Members
449,072
Latest member
DW Draft

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top