I just populated a table via an algorithm with data from an Autodesk file. A good many of the fields are empty, and, in fact, a number of columns are empty but for a few rows. There are roughly 1300 columns, and I'm trying to trim that down.

Can anyone help me out with the VBA to remove a column if there are more than 1000 rows where the column is empty? I don't really know any VBA, so I don't know where to begin...

I'm trying something like this:

```html
Sub ClearColumns()
'
' ClearColumns Macro
' Check to see if more than 1000 rows of a column are empty.  If so, delete the column.

Dim iColumn As Long
Dim iRow As Long
Dim iColumnMax As Long
Dim iRowMax As Long
Dim iEmptyCount
iColumnMax = 13000
iRowMax = 20000

For iColumn = 1 To iColumnMax
    For iRow = 1 To iRowMax
        If (Cells(iRow, iColumn) = "") Then iEmptyCount.Add (1)
        End If
    If (iEmptyCount > 999) Then Columns(iColumn).Delete
    Step 1
    End If
Step 1     
Application.Goto Reference:="ClearColumns"
End Sub
```

But again, I don't know what I'm doing. Any help/feedback is appreciated