cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper I
Helper I

Filtering problem.

I search the forums but cant seem to find anyone with the same issue. 

 

So, I have one screen that is used to search members, and a second screen that displays the members in the gallery, but when i enter the formula listed below i get a error message stating" invalid argument type(number), Expecting a (text)... anyone know a way to solve this or a alternative formula with the same results?

 

Thanks in advance 

 

 

Screen Shot 2020-02-08 at 3.47.16 PM.png

Screen Shot 2020-02-08 at 3.44.21 PM.png

4 REPLIES 4
Highlighted
Super User
Super User

Re: Filtering problem.

@Grunt1772
The StartsWith function cannot be used with Number values. At least one of the values in each highlighted formula is a Number. You could modify your formula similar to this to attempt to fix the problem.

StartsWith(Text(your_value_1, “0”), Text(your_value_2, “0”))


Please Accept as Solution if this post answered your question so others may find it more quickly. If you found this post helpful consider giving it a Thumbs Up.
Highlighted
Helper I
Helper I

Re: Filtering problem.

MD,

 

Thanks for the rapid response. Tried it with no luck. Have anything else up your sleeves that might help ?

 

Thanks

Highlighted
Super User
Super User

Re: Filtering problem.

@Grunt1772
Nope that’s all I’ve got. Using text on both, or one of either should work here.
Community Support
Community Support

Re: Filtering problem.

@Grunt1772 

 

What is the Data Type of TAXID and MEMBERAGREENBR Columns?
From the Error message and Syntax of StartsWith function, we can know that the StartsWith can only handle with Text field.

Your formula should be like this:

StartsWith(Text(TAXID), Text(Varssn)) And StartsWith(Text(MEMBERAGREENBR), Text(Varaccntnum))

If your data source is form SharePoint, there could be a delegation issue. Here is the workaround for avoiding delegation error if needed.
1. create a new Gallery, set Items property to MembersCombine, then the gallery will display all items from sharepoint
2. apply 'Gallery.AllItems' statement into the code, instead of MembersCombine, the delegation error will be fixed.

Filter(Gallery.AllItems, .... And StartsWith(Text(TAXID), Text(Varssn)) And StartsWith(Text(MEMBERAGREENBR), Text(Varaccntnum)))

3. set the Gallery Visible property to false because there is no need to display this gallery.

Sik

Helpful resources

Announcements
secondImage

New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

August 2020 CYST Challenge

Check out the winners of the recent 'Can You Solve These?' community challenge!

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

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