//Patch the Info and the Choice and get the list ID
Set(TempCol, Patch ('New PO Request - MC ST OKC', Defaults('New PO Request - MC ST OKC'),
{
Title:txt_Vendor.Text
}));
//Update with patch function and the attachments and the choices
Patch('New PO Request - MC ST OKC', LookUp('New PO Request - MC ST OKC',ID=TempCol.ID);
{
},fmAttachment.Updates);
ForAll(
gal_OrderItems.AllItems,
Patch(
'New PO Request - MC ST OKC',
Defaults('New PO Request - MC ST OKC'),
{
Title:txt_Vendor.Text,
'Reason for purchase': txt_Purchase.Text,
Items:txt_Item.Text,
'Charged back?': tgl_CB.Value,
'DT/Customer Name': txt_Customer.Text,
Office:ddOffice.SelectedText,
Qty: txt_Qty.Text,
'Item Cost': txt_Price.Text,
Description:txt_Desc.Text
}
);
Notify("Data successfully submitted to Sharepoint",NotificationType.Success,4000);
Concurrent(
ResetForm(fmAttachment),
Reset(gal_OrderItems)
))