Hi Community,
I am trying to build an app where I am sending the information to a sharepoint list using a flow. There a several fields using texts, values and also attachments.
Below the code I am using at the moment, but unfortunatley I am only able to attach one file, but I would like to attach several instead.
I tried quiet some time using the ForAll(DataCardValue150.Attachments), but I couldn´t get it working properly.
Can someone help me, please?
Sebastian
______________________________________
Safety.Run(
Text(
If(IsBlank(DataCardValue56.SelectedDate); Today(); DataCardValue56.SelectedDate);
"yyyy-mm-dd"
);
If(IsBlank(DataCardValue141.Text); ""; DataCardValue141.Text);
If(IsBlank(DataCardValue95.Text); ""; DataCardValue95.Text);
If(IsBlank(DataCardValue118.Text); ""; DataCardValue118.Text);
If(IsBlank(DataCardValue142.Selected.Value); ""; DataCardValue142.Selected.Value);
If(IsBlank(DataCardValue143.Selected.Value); ""; DataCardValue143.Selected.Value);
If(IsBlank(DataCardValue59.Selected.Value); ""; DataCardValue59.Selected.Value);
If(
CountRows(DataCardValue150.Attachments) > 0;
{
file: {
name: First(DataCardValue150.Attachments).Name;
contentBytes: First(DataCardValue150.Attachments).Value
}
};
{}
)
);;
Navigate(SafetyScreen);;
ResetForm(Form7)