cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ben_C
Resolver II
Resolver II

Filter Canvas app list unique varilable

I have two canvas app list gallery which pulls from a SharePoint list of messages between project team and clients. the first filters the list depending on the current user like this:

 

Filter('Source', AssignedUser.Email = User().Email)

 

If the client replies I have set the app to create a new list item for further messages from the project team. 

 

I'm attempting to get the list second gallery item to filter the assigned users column but only list the new reply list items. 

 

Filter('Source List', AssignedUser.Email = User().Email || Not(IsBlank(ReplyID))

 

However this as expected brings back all items assigned to the user, regardless if it is a first response or a follow on response. 

 

Any suggestions would be most helpfull. 

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @Ben_C ,

It is not clear from your post how you identify the "follow on response", but if you want the latest response

LookUp(
   Sort(
      'Source List', 
      ID,
      Descending
   ),
   AssignedUser.Email = User().Email || !(IsBlank(ReplyID))
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

View solution in original post

4 REPLIES 4
WarrenBelz
Super User
Super User

Hi @Ben_C ,

It is not clear from your post how you identify the "follow on response", but if you want the latest response

LookUp(
   Sort(
      'Source List', 
      ID,
      Descending
   ),
   AssignedUser.Email = User().Email || !(IsBlank(ReplyID))
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

Hi @WarrenBelz, sorry I forgot to mention I have a lookup column to the client reply list which looks up the ID pof the reply. The second response list item is created when the client submits a reply and that lookup column is populated. 

Hi @Ben_C ,

So is that still not the newest response? If not what attributes will it have? Also I suggest you think hard about using Lookup columns - they are generally not needed and will cause you more unnecessary grief than you need.

Ben_C
Resolver II
Resolver II

I've just realised I have used the wrong operator. I don't want OR I wanted to use AND.

 

 

Filter('Source', AssignedUser.Email = User().Email && Not(IsBlank(ReplyID.Value)))

 

 

This still dosen't bring back just the current replies however. 

 

---EDIT---

 

Also realised that the test data I was using wasn't assigned to anyone. So it was working afterall. 

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (4,642)