How do I Patch the Attachment control content along with the rest of the screen content?
Everything is in a Gallery.
Patch(PO_Tracking_Davis_Production,
Defaults(PO_Tracking_Davis_Production),
{Title: New_PO_Machine_Serial_Number_Fld.Text,
Machine_Model: New_PO_Model_Fld.Selected.Value,
Customer_Name: New_Customer_Name_Fld.Text,
Sold_Date: New_PO_Sold_Date_DatePicker.SelectedDate,
Sold: If(New_PO_Sold_Checkbox.Value,{Value:"Yes"},{Value:"No"})
})
Hi @Phineas ,
As far as I know, PowerApps doesn't support to update files to attachments column of SP list via Patch function.
I recommend you use SubmitForm to update files to attachments column.
There is a workaround for your reference:
Create two buttons and a form with attachment field.
1.OnSelect of Button1:
Patch(PO_Tracking_Davis_Production,
Defaults(PO_Tracking_Davis_Production),
{Title: New_PO_Machine_Serial_Number_Fld.Text,
Machine_Model: New_PO_Model_Fld.Selected.Value,
Customer_Name: New_Customer_Name_Fld.Text,
Sold_Date: New_PO_Sold_Date_DatePicker.SelectedDate,
Sold: If(New_PO_Sold_Checkbox.Value,{Value:"Yes"},{Value:"No"})
})
2.OnSelected of Button2:
SubmitForm(Form)
3.Item of Form:
First(SortByColumns(PO_Tracking_Davis_Production,"ID",SortOrder.Descending))
Best regards,
Rimmon
WarrenBelz
146,524
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,906
Most Valuable Professional