S
Stephen sjw_ost
I am trying to figure out how to put border lines around each cell in my
excel data. I am using automation from access but the code I am using is only
putting a border around everything instead of putting the border around each
cell. Below is the code I have been trying to get to work.
*********************************************
Dim x, y As Long
x = 4 'initial row#
y = 1 'initial column#
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(7).Weight = 2
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(8).Weight = 2
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(9).Weight = 2
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(10).Weight = 2
***********************************************
Thanks for any help,
excel data. I am using automation from access but the code I am using is only
putting a border around everything instead of putting the border around each
cell. Below is the code I have been trying to get to work.
*********************************************
Dim x, y As Long
x = 4 'initial row#
y = 1 'initial column#
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(7).Weight = 2
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(8).Weight = 2
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(9).Weight = 2
ExSheet.Range(ExSheet.cells(x, y), ExSheet.cells(x + 2, y +
2)).Borders(10).Weight = 2
***********************************************
Thanks for any help,