
Announcements
I created an Excel using Power Automate, with Table and Rows filled.
As there is no OOTB feature available to sort tables during the creation of Excel and Tables, is it possible to implement a script of the following requirement?
1. Select a table in the first sheet of an Excel
2. With the table containing headers, sort column H by ascending Date
If it is possible, I appreciate any help with regards to forming the script.
Thank you.
Hi @SysAdmSG ,
Please try this
function main(workbook: ExcelScript.Workbook) {
let table1 = workbook.getTable("Table1");
// Sort on table: table1 column index: '7'
table1.getSort().apply([{key: 7, ascending: true}]);
}
Best Regards,
Wearsky