Hi all,
Scenario:
I have a Canvas app where I created a dynamically populated gallery that lets users type in various bits of info - essentially a form with dynamically changing fields. I then store the results in a collection using the below code, which is great, but my results are stored in 2 columns.
The end aim here is to be able to export the data to power automate so an xml schema can be inserted into a word file.
How do I transpose them to be a single row table with the item names in the ID column to be my column names? My problem is, the names and the number of items keep changing. I couldn't find a transpose function in powerapps (which I definitely took for granted in Excel).
I'm aware I'll probably have to rethink, but I'm pretty stuck with all this data manipulation in PowerApps
Any ideas? Thanks so much
Clear(tempCollection);
ForAll(
GalleryDynamicItems.AllItems,
Collect(
tempCollection,
{
id: ID,
Value: If(
Type = "Textbox",
TextInput1.Text,
Type = "Dropdown",
Dropdown1.Selected.Result,
DatePicker1.SelectedDate
)
}
)
);
This is the result:

What I want is this:
