Hi Everyone,
I have a SharePoint list with multiple content types. The list has a PowerApps form, and I have a collection that contains all values of the content types. I have a dropdown in the form that allows users to select the content type, which is then used in the form for column visibility.
How do I update the content type in the list with the selected one, currently it takes the default content type that's been set in the list? I've tried using a Patch function with LastSubmit and Defaults, but it updates the SharePoint item with no value (I can see a new version, but no update).
Content Type Collection in PowerApps
ClearCollect(ContentTypes, {Id:"0x01001D0D916AXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX3FC8F50AB5FAA17", ContentTypeName:{Value:"Name"}, Name:"ContentTypeName"})
Content Type Dropdown - OnChange property:
Set(SelectedContentType, First(Self.SelectedItems))
Patch function I used:
Patch(
LISTNAME,
SharePointForm1.LastSubmit,
{
'Content type': SelectedContentType
}
)
There is nothing in the Default property or DefaultSelectedItems for the content type dropdown.
Please help me with this.
Thanks in advance!
Divya

Report
All responses (
Answers (