Hi @FabianAckeret ,
Could you please share a bit more about the "status" column in your SP List? Is it a Text type column or a Choice type column?
Do you want to change the status column value in your Edit form via clicking the 6 buttons, and set default value to "in progress" when open a new form, keep Parent.Default when open a edit form?
Based on the needs that you mentioned, I have made a test on my side, please take a try with the following workaround:
Set the OnSelect property of the Button1 to following:
Set(varStatus, "active")
Set the OnSelect property of the Button2 to following:
Set(varStatus, "inactive")
Set the OnSelect property of the Button3 to following:
Set(varStatus, "cancelled")
...
Set the OnSelect property of the Button6 to following:
Set(varStatus, "in progress")
Set the OnNew property of the SharePointIntegration control to following:
Set(varStatus, Blank()); /* <-- Add this formula */
NewForm(SharePointForm1)
Set the OnEdit property of the SharePointIntegration control to following:
Set(varStatus, Blank()); /* <-- Add this formula */
EditForm(SharePointForm1)
Set the OnView property of the SharePointIntegration control to following:
Set(varStatus, Blank()); /* <-- Add this formula */
ViewForm(SharePointForm1)
1. If the "status" column is a Text type column in your SP List:
Set the Default property of the Text Input box within the "status" data card within the Edit form to following:
If(
!IsBlank(varStatus),
varStatus,
If(
SharePointForm1.Mode = FormMode.New,
"in progress",
Parent.Default
)
)
2. If the "status" column is a Choice column in your SP List:
Set the DefaultSelectedItems property of the ComboBox box within the "status" data card in the Edit form to following:
If(
!IsBlank(varStatus),
{
Value: varStatus
},
If(
SharePointForm1.Mode = FormMode.New,
{
Value: "in progress",
},
Parent.Default
)
)
Please consider take a try with above solution, then check if the issue is solved.
Best regards,