Hi everyone,
I have a controlled gallery that populates data from an excel sheet (which I don't want to update) to a word template so I can't use patch, refresh etc.
Currently I use a formula in 'onselect' of my submit button.
ClearCollect(
FilteredData,
ForAll(
Filter(
DrPreferenceList,
'Dr. Name' = 'Preference Dr Name'.Selected.'Dr. Name',
'Preference List' = 'Preference List App'.Selected.Value
),
{
System: System,
Product: Product,
Qty: Qty,
Notes: Notes
}
)
);
ForAll(
FilteredData,
BookingFormTable.Run(
'Surgeon name'.Selected.'Dr. Name',
'Hospital name',
'Booking date',
'Preference List App'.Selected.Value,
'Preference List App'.Selected.Value,
'Rep name',
'Procedure date',
'Procedure name',
'Patient name',
JSON(FilteredData)
)
)
{
"type": "array",
"items": {
"type": "object",
"properties": {
"System": {
"type": "string"
},
"Product": {
"type": "string"
},
"Qty": {
"type": "integer"
},
"Notes": {
"type": "string"
}
},
"required": [
"System",
"Product",
"Qty",
"Notes"
]
}
}
I tried setting the formula as below
ClearCollect(
FilteredData,
ForAll(
Filter(
DrPreferenceList,
'Dr. Name' = 'Preference Dr Name'.Selected.'Dr. Name',
'Preference List' = 'Preference List App'.Selected.Value
),
{
System: System,
Product: Product,
Qty: Value(ThisItem.Qty.Text),
Notes: ThisItem.Notes.Text
}
)
);where it show the changes but it overwrites the first row of the 'notes' and 'qty' to other rows.
My initial problem was that the table in my word template only showed the first row of the gallery.
Since now I'm collecting the gallery data I can see my data perfectly in my word doc but I can't see the edited value or that I can't achieve PowerApps to collect the edited data without an issue of serialisation, local data collection etc.
Since I'm new, I feel like I'm making an easy process complicated 😞
Please help!

Report
All responses (
Answers (