0

createXLSX

 Has anyone managed to figure out how to implement this to your script using the new createXLSX function?

2 replies

null
    • Fred
    • 7 mths ago
    • Reported - view

    Those look like Excel formulas. Which makes sense as you are creating Excel files. Which means you need to map out the columns and rows in your mind or in an test Excel file so you can see the columns/rows Ids you will need to use in your formulas.

    I would guess, since I haven't tried it out yet, if you wanted do a count of a column you would do something like:

    countOfItems = {formula: 'SUM(A,A}'}

    So this would count the entire A column.

    Which means you will need to know the exact Excel formula.

    Ninox doesn't show anything about building your JSON dynamically, but I'm guessing you can.

    • Fred
    • 7 mths ago
    • Reported - view

    Had a chance to play around a bit and you can build your JSON dynamically. In my test DB i have the following code for the rows variable:

    let rows := (select InvoiceItems).[{
        name: Products.Item,
        age: Qty,
        url: Invoice.InvoiceNum,
        description: MC1,
        }];
    

    And it builds the XLSX file just fine.

    One thing I can't figure out is how to create a summary row at the bottom. I tried creating a second row variable, but that didn't work.

Content aside

  • 7 mths agoLast active
  • 2Replies
  • 139Views
  • 2 Following