cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AIUYM19
Level: Powered On

Invalid argument type when comparing two text values

I have a button on a screen which has the following forumla in the OnSelect property.

UpdateContext({
    galVis:true, frmViewVis:false, 
    dsFiltered:Filter(ds, And(Not(Status.Value="Complete"), Assignee.Email=User().Email))
})

ApowerApps gives me an error on the equals sign between Assignee.Email and User().Email. It throws an error of "invalid argument type." I don't understand why it is throwing this error, because both of those values should be text. The Assignee field in the data source is a SharePoint list item of Person or Group type, limited to a single entry.

 

My goal is to filter the gallery on items that have a status of anything except "Complete" and where the Assignee email address matches the email address of the current user. Any ideas?

1 ACCEPTED SOLUTION

Accepted Solutions
jhall
Level 8

Re: Invalid argument type when comparing two text values

You might try First(Assignee).Email.  Just know that some SharePoint values per users are lists even if you specify that a single value exists.

View solution in original post

2 REPLIES 2
jhall
Level 8

Re: Invalid argument type when comparing two text values

You might try First(Assignee).Email.  Just know that some SharePoint values per users are lists even if you specify that a single value exists.

View solution in original post

AIUYM19
Level: Powered On

Re: Invalid argument type when comparing two text values

Thank you. This took care of the error. Smiley Happy Now I have a new problem, but it's a different question about how the User() function works.

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Demo Extravaganza Championship Voting Open

Voting Ends: October 30, 2019!

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

Top Kudoed Authors
Users Online
Currently online: 449 members 5,471 guests
Please welcome our newest community members: