You need to specify which border you're setting. Currently you're setting it
for all borders.
Change:
range.Columns.Borders.LineStyle = Excel.XlLineStyle.xlContinuous;
To:
range.Columns.Borders[Excel.XlBordersIndex.xlEdgeRight].LineStyle =
Excel.XlLineStyle.Continous;
range.Columns.Borders[Excel.XlBordersIndex.xlEdgeLeft].LineStyle =
Excel.XlLineStyle.Continous;
"Kalaora luc" <lu********@free.fr> wrote in message
news:O1**************@TK2MSFTNGP10.phx.gbl...
I transfert data in a Excel File.
I want that the border of the cell in Excel have only left and right
border.
if i do :
range.Columns.Borders.LineStyle=Excel.XlLineStyle. xlContinuous;
My cell have up, down, left ,right borders. How can have only left and
rigth border ?
Thanks for your answer
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!