cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PietroFarias
Regular Visitor

Sharepoint form field is not added to the list

I customized a form from a Sharepoint list.

I add two fields from a list to a form, both of which are dropdown. In the first field, the user must enter a SUBCATEGORY. The second field will be the CATEGORY. It turns out that I disabled the CATEGORY field and include a VLOOKUP function to return the name of the correct category. When saving the report through Sharepoint, only the SUBCATEGORY item is added to the list. The CATEGORY field is only added if the field is filled in by the user.

Question: How do I add the CATEGORY field to the list like this?

1 ACCEPTED SOLUTION

Accepted Solutions
PietroFarias
Regular Visitor

I decided based on the video by Reza Dorrani. I made some changes and it worked perfectly.

Cascading Dropdowns in Power Apps from SharePoint list or Excel - YouTube

View solution in original post

3 REPLIES 3
v-jefferni
Community Support
Community Support

Hi @PietroFarias ,

 

Could you please share more details about your scenario? Do you have another list which includes Category column and Subcategory column? Then would you like to make the category dropdown automatically populate with the corresponding category after subcategory is selected? What column types are the two columns, Choices or LookUp?

 

Assuming that category is a Choices type column and Subcategory is a LookUp type column in current SP list, and a Text type Subcategory column and a Choices Type Category column, since you use a LookUp to auto populate a corresponding category in the dropdown, you will need to modify the Update property of Category Data Card to:

LookUp(Choices(ListName.Category),Value = CategoryDropdown.Selected.Value)

 

Below is a test on my end:.

1\ List 1 includes Text column and Choices column, list2 includes LookUp column and Choices column:

141.png

142.png

2\ DefaultSelectItems of Combo box of Choices column is set to below formula and DisplayMode set to Disabled:

LookUp(list1,Title1 = DataCardValue2.Selected.Value).TestColumn

 

3\ Update of the data card which includes the disabled combo box is set to:

LookUp(Choices(List2.Test123),Value = DataCardValue1.Selected.Value)

 

Hope this helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

@v-jefferni 

I did the update, and it works when changing or adding an item. However, when I make the same change to the item, it does not work.


Your Answers:

[1] Then would you like to make the category dropdown automatically populate with the corresponding category after subcategory is selected? 

YES

 

[2] What column types are the two columns, Choices or LookUp?

In Sharepoint, both are VlookUp

 

 

Based on what you answered, I did it as follows:

 

1. In the CATEGORY dropdown in 'DefaultSelectedItems' I put:

LookUp (SubcategoryList, Title = DataCardValue_Subcategory.Selected.Value).Category 


In 'Category_DataCard' I changed the 'Update' property to:

LookUp (Choices (SubcategoryList.Category), Value = DataCardValue_Subcategory.Selected.Value)
PietroFarias
Regular Visitor

I decided based on the video by Reza Dorrani. I made some changes and it worked perfectly.

Cascading Dropdowns in Power Apps from SharePoint list or Excel - YouTube

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (1,369)