cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Yajjoj
Frequent Visitor

Clear People picker field in PowerApps

I am tried many ways to clear the filed in SharePoint list using PowerApps and make it null on the record.
but unfortunately, I could not do that.

## first way I tried:

 

 

    Set(
    BlankPerson,
    Table(
        {
            Claims: Blank(),
            DisplayName: Blank(),
            Email: Blank(),
            Department: Blank(),
            Picture: Blank(),
            JobTitle: Blank()
        }
    )
    );

    Patch(
        'InvoicePaymentRequests',
        {ID: InvoicesListGallery.Selected.ID},
        {SecondApprover: BlankPerson()}
    );

 

 

**I am getting mismatch data type (Record - Table) **

## Second way I tried

 

 

Patch(
        'InvoicePaymentRequests',
        {ID: InvoicesListGallery.Selected.ID},
            {
                SecondApprover: {
                    '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
                    Claims: Blank(),
                    DisplayName: Blank(),
                    Email: Blank(),
                    Department: Blank(),
                    Picture: Blank(),
                    JobTitle: Blank()
                }
            }
    );
    Refresh(InvoicePaymentRequests)

 

 



**this one it is running but will not clear the field value on the list.**

## Third way

 

 

    
    Patch(
        'InvoicePaymentRequests',
        {ID: InvoicesListGallery.Selected.ID},
            {
                SecondApprover: Blank()
            }
    );

 

 



**also did not work**

any suggestions?

thanks and best regards

1 ACCEPTED SOLUTION

Accepted Solutions

Checkout the link i shared before. So many people face the same issue. The only solution right now is enable formula level error management. And save the app. And reload. 

I am sorry i couldn't be more helpful.

View solution in original post

7 REPLIES 7
zmansuri
Super User
Super User

Is the people picker field in form as a combo box?

If yes you don't need to do anything code wise. Just enable Formula level error management from advance settings in your PowerApps. Save and publish the app. and done.

Yajjoj
Frequent Visitor

Yes it is combo box, but still not working even after enabling the Formula level error management 😞

Right now it is the only way to make person field blank. It works for me. 

You can also try this.

Go to the Datacard of that people picker field. Select the datacard not the combo box. Go to it's update property.

Write:

If(Isblank(datacardname),Blank(),datacardname.selected)

https://powerusers.microsoft.com/t5/Building-Power-Apps/Reset-a-ComboBox-people-picker-to-blank/m-p/...

 

Checkout this. You must be missing something. There is no need to write complicated patch code to write blank value. 

Yajjoj
Frequent Visitor

I add it to the datacard as below on update property

Spoiler
If(Isblank(DataCardValue42),Blank(),DataCardValue42.selected)


and it did not work, I even make it Blank() only and still not owrking.
am I missing somthing ?

 

Yajjoj
Frequent Visitor

I add it to the datacard as below on update property: 

Spoiler
If(Isblank(DataCardValue42),Blank(),DataCardValue42.selected)


and it did not work, I even make it Blank() only and still not owrking.
am I missing somthing ?

 

Checkout the link i shared before. So many people face the same issue. The only solution right now is enable formula level error management. And save the app. And reload. 

I am sorry i couldn't be more helpful.

Helpful resources

Announcements
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.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (3,064)