web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Invalid argument type ...
Power Apps
Answered

Invalid argument type on a Filter function

(0) ShareShare
ReportReport
Posted on by 574

Hi all

 

This makes no sense to me. I have this working on other Apps ...

The following is working fine:

Filter('Sales department', Email = EmployeeEmailAddressVariable)

But this ain't:

Filter(If(Department= "Sales department",'Sales department'), Email = EmployeeEmailAddress)
If(Department= "Sales department",Filter('Sales department', Email = EmployeeEmailAddress))

I am getting "Invalid argument type" on the equals sign '=' for the Department check.

Department & EmployeeEmailAddress are variables i set using the Set(name,value) function, the Email is a column from Sharepoint and 'Sales department' is a Source from SharePoint that is connected to my app.

I tried including a Source ('Sales department') in the else part but same results.

Can anyone elaborate on this for me please.

 

Thank you

Categories:
  • Verified answer
    ITCareNV Profile Picture
    574 on at

    Seems that when I am Querying a Source (SharePoint list) with the use of Filter and setting this result to a Variable, if I want to use the value of this Variable afterwards I need to use .Value in order to "use" the Variable value.

     

    This fixed it for me.

     

    In other cases (other apps) where i used the same logic and syntax, the difference is that i am setting the variable from a DropDown selected value and not a Source like Sharepoint which can give more than 1 result, so this is the reason (i guess) the .Value is needed for.

     

    Hope this can help someone Cat LOL

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 339 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 289

#3
Mohsin Ali Profile Picture

Mohsin Ali 228

Last 30 days Overall leaderboard