I have an incoming sheet (sheet 1) that gets entries through a userform and it allows users to request up to 5 items per form submission. Each item goes into its own column (Column1 through Column5). Then I have a bridge workflow that is triggered when a new row is added to sheet 1. This workflow creates a new row for each item on sheet 2, then deletes the row that triggered the workflow from sheet 1, and finishes up with sorting sheet 2.
This works laid out as you can see below, but I'd like to consolidate and just do one addRow action.
I do have a column that shows the number of items that were entered, so I could use that for the number of iterations needed, or go until it finds a column with no entry, or it tops out at 5.
I'm thinking it might be something like…
If column1 <> "" Then create newRowArray1
If column2 <> "" Then create newRowArray2
If column3 <> "" Then create newRowArray3
If column4 <> "" Then create newRowArray4
If column5 <> "" Then create newRowArray5
AddRow on sheet 2 for all newRowArrays
Sort sheet 2
DeleteRow from sheet 1.
Not sure the best way to do all this… Maybe a child workflow to create each of the new row arrays? Is bulk addrows an api call?