I have the following code attached and for some reason when it tries to run the code to add borders around the cells a second time I get the following error just for the inside borders. Run time error 1004 - Unable to set the LineStyle property of the Border class. When I comment out the line so it ignores the code it works great but of course no lines. The code that I'm having trouble with is commented out. It's part of the PopulatePartsByVendor sub procedure. Basically the code is to export data to excel spreadsheets. Any ideas?