Loop - export Excel

L

learning_codes

Hi,

I have 50 spreadsheets that have one worksheet. I have all the data
in each spreadsheet but only first (1 of 50) has the lines. This is
what I want but I am not able to get all next 49 spreadsheet does not
have the lines.

Can you help me and how to create all the spreadsheets that have
lines?

Your help would be much appreciated.

Here is the code below:


'*********************************************************************
For Each cell In Range("A4", Range("A65536").End(xlUp))
If cell.Value > "" Then
With Range(cell, cell.Offset(0, 9))

With .Borders(xlEdgeLeft)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeTop)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeRight)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With .Borders(xlInsideVertical)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With

End With

End If
Next
 
A

Arvin Meyer [MVP]

First of all, that is only a snippet from the entire code, so there's no way
that we can see how this would relate to an Access export. I suspect that
you'd be better off asking this in an Excel newsgroup anyway, since all the
code below is Excel VBA.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top