I have a form where users enter Vendor Address and Payment Address. Most times they are the same so I want to set the Default value for the Payment fields to equal the Vandor Address. My formula is working for Text fields and all but one dropdown.
Example: For the Payment Vendor Name, the Default = If(SharePointForm1.Mode = New,If(VenPayAdd.Selected.Value = "Yes",VenName1.Text,""),ThisItem.'Payment Vendor Name 1')
Where VenPayAdd is the selection of the Payment address being the same or not. By Default that is Yes and all text fields are working as expected.
The Vendor Country(VenContrydd) is a DropDown selection from a secondary list: Sort(Distinct(VendorDataList,Country),Result)
The Country Payment Dropdown default is working with this Formula:
If(SharePointForm1.Mode = FormMode.New,If(VenPayAdd.Selected.Value = "Yes",VenContrydd.Selected.Result,"-"),ThisItem.PayVenCountry)
Where I am running into an issue is that the Vendor State Dropdown(VenStatedd) is a Filtered Dropdown selection from that secondary list depending on the Country selected : Filter(VendorDataList, Country = VenContrydd.Selected.Result)
When I get to the Payment State field, it doesn't like the Filtered data result as a "selected result":
If(SharePointForm1.Mode = FormMode.New,If(VenPayAdd.Selected.Value = "Yes",VenStatedd.Selected.Result,"-"),ThisItem.PayVenState)
"Result" gives "Identifier not recognized".. When I enter the "VenStatedd." I get options of "Selected" and "SelectedText" but both give errors when selected.
In the screenshot below you can see that currently the Payment State is being set to the first filtered value (AL) rather then what I selected in the Vendor State.. Whereas the Payment Country dropdown is the same as the Vendor Country..
Solved! Go to Solution.
Figured this out by using another field I had in the App.
To pass the Value of the Vendor State selected by the user back to SAP, I had created a Text field named "VenState" which has a default value of: VenStatedd.SelectedText.Value
So, for the Payment State Default I used that field value if it is a new item being created:
If(SharePointForm1.Mode = FormMode.New,If(VenPayAdd.Selected.Value = "Yes",DataCardValue36.Text,"-"),ThisItem.PayVenState)
And Viola.. If they leave "Payment is the same as vendor" as "Yes" then the Payment State defaults to the Vendor State:
Figured this out by using another field I had in the App.
To pass the Value of the Vendor State selected by the user back to SAP, I had created a Text field named "VenState" which has a default value of: VenStatedd.SelectedText.Value
So, for the Payment State Default I used that field value if it is a new item being created:
If(SharePointForm1.Mode = FormMode.New,If(VenPayAdd.Selected.Value = "Yes",DataCardValue36.Text,"-"),ThisItem.PayVenState)
And Viola.. If they leave "Payment is the same as vendor" as "Yes" then the Payment State defaults to the Vendor State:
Hi @shanemeisner ,
Have you solved your problem?
Is the "State" column a Text type column in your list?
If you have solved your problem, please consider go ahead to click "Accept as Solution" to identify this thread has been solved.
Best regards,
Thanks for the reminder.. The State field was a text field that holds the value needed to send over to SAP and I marked my answer as the solution that worked.
Stay up tp date on the latest blogs and activities in the community News & Announcements.
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
User | Count |
---|---|
218 | |
208 | |
85 | |
57 | |
36 |