Help me 1

  • Thread starter Thread starter TIMOTHY
  • Start date Start date
T

TIMOTHY

I want to autofilter a range using vba, which is the right way, after
making it a table or range is enough
 
I want to autofilter a range using vba, which is the right way, after

making it a table or range is enough

Hi Timothy,

Here's one of many ways. Probably need a fair amount of tweaking to suit your exact needs.

Option Explicit
Sub FillRng()
Dim i As String
Dim c As Range
i = "A Choice"

' i could be an item from a drop down list
' If so then i = range("A1").value (drop down in A1)
For Each c In Range("E2:G10")
If c.Value = "" Then c.Value = i
Next

End Sub

HTH
Regards,
Howard
 
Back
Top