Announcement

Collapse
No announcement yet.

Luacom and Excel borders

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Luacom and Excel borders

    I'm using luacom to manipulate excel files with a degree of success but i cant seem to change borders on a range of cells.

    So far i have:

    Code:
    oExcel = luacom.GetObject("Excel.Application");
    Book = oExcel.Workbooks:Open(_DesktopFolder .. "\\document.xlsx");
    Sheet = Book.WorkSheets(1);
    
    RangeRef = "A3:E" .. nEntries + 3
    local BorderList = Sheet:Range(RangeRef)
    
    BorderList:Select();
    I know the next part is something like this:

    Code:
    BorderList.Borders(xlEdgeLeft).LineStyle(xlContinuous)
    but i get errors returned:

    "Error: "

    Anyone with any experience with luacom and excel out there?
    Thanks
Working...
X