I need some help writing a JS workflow that will custom filter and sort a subtable. This workflow is to be triggered by an action button. The idea is to automatically prepare a subtable for an Excel mail merge. My idea is to create the following three action buttons, and then combine them for a one button workflow:
- Custom sort and filter subtable on the current sheet
- Mail merge Excel template export
- Clear custom sort and filter on the subtable (restore default settings)
Can someone help write the code here, or let me know how to use AI to write it for me? Thanks in advance~