Skip to main content

Notifications

Community site session details

Community site session details

Session Id : 4+j00ztKqIJDOp+fFzvzyE
Power Apps - Building Power Apps
Unanswered

Create metadata tags through powerapps newform - SharePoint

Like (0) ShareShare
ReportReport
Posted on 30 Nov 2020 04:34:47 by 494

Hi All,

 

I have a Powerapps newform which is used to create a new record in SharePoint. In my newform, I have a tag field, which is used to store metadata tags in SharePoint. Metadata taxonomy column appear as a combo box in Powerapps form as in screenshot below.

 

tagg.PNG

I would like to have users key-in their own tags in Tag field and that tag should get saved into metadata field in SharePoint, once they submit the powerapp newform.

 

Please let me know if it can be done via powerapps. Any advice would be helpful. Thanks.

 

Categories:
  • v-jefferni Profile Picture
    on 07 Dec 2020 at 02:59:16
    Re: Create metadata tags through powerapps newform - SharePoint

    Hi @Iantaylor2050 ďĽŚ

     

    The formula I provided was to save search text in Combo box's search area to SP list as the Title column value if there is no item selected in the combo box. This is the only way to add a new item within combo box since there is no more place of a combo box to type in.

     

    About your first question, if it is a LookUp column means it retrieves records from another list so you will have to add records to the list being looked up then the LookUp column could find the new items. 

     

    If you really want to make users type in new items clearly and save them to SP list when there is no item could and has been selected, you could add a TextInput box in the data card upside or beside the default combo box and turn off the search feature of the combo box, then make typed in text of the TextInput box as the search text or the source of new item instead. 

     

    I made a mistake in above formula that submitted the form without setting the LookUp column value, but with the help of the method of adding a TextInput, you could add another button such as a plus icon if needed to add a new item to the lookup list, with the formula below:

    If(IsBlank(LookUp(LookUpList,Title=TextInput.Text)),
    Patch(LookUpList,
     Defaults(LookUpList),
     {Title:TextInput.Text} // All requied columns need to set the value here
    ),
    Notify("The tag has already exists, please select in the dropdown!",NotificationType.Warning)
    //To warn and avoid duplicate items
    )

    The the Update of the LookUp column Data Card should be:

    If(!IsBlank(DataCardValue.Selected),
     DataCardValue.Selected,
     LookUp(LookUplist,Title=TextInput.Text)
    )

    Then the submit button only need to be SubmitForm(NewForm)

     

    Since within one button we could not trigger two submit action point to one SP list, the add button of the new tag is required so that users could first add a tag to LookUp list then when submitting the form the lookup column have a value to look up from.

     

    Hope I have explained clearly and 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.

  • Iantaylor2050 Profile Picture
    494 on 05 Dec 2020 at 13:23:16
    Re: Create metadata tags through powerapps newform - SharePoint

    Hi @v-jefferni 

     

    Thanks for your response.

     

    Yes, you are correct. I would you like to let users manually type in the tags in the combobox then save it to termstore field in SP list.

     

    The approach you mentioned is to create a lookup column. When I add record via lookup column, it doesn't save into the termstore right ?

     

    Is there a way where we can directly save combobox added term into the termstore field in SharePoint ?

     

  • v-jefferni Profile Picture
    on 30 Nov 2020 at 11:29:26
    Re: Create metadata tags through powerapps newform - SharePoint

    Hi @Iantaylor2050 ,

     

    Could you please share more details about your scenario?

     

    Would you like to let users could manually type in the tags in the combo box then save it to SP list?

     

    As per you mentioned that the Metadata taxonomy column appear as a combo box in Powerapps form, then it should be a LookUp column, if so, you will need to modify the OnSelect property of the submit button to:

    SubmitForm(NewForm);
    If(
     !IsBlank(DataCardValue.Selected),
     DataCardValue.Selected,
     Patch(LookUpList,
     Defaults(LookUpList),
     {Title:DataCardValue.SearchText} // All requied columns need to set the value here
     )
    )

     

    Otherwise, the Update of that data card should be cleared to blank.

     

    Notice: This solution would only be used when that is a New Form. If you are working with EdidForm in NewMode, this would occur errors in updating the tag 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.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,658 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,999 Most Valuable Professional

Leaderboard
Loading started