cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ClaireAllen
Post Partisan
Post Partisan

Filter Gallery by ID to only show current item

Hello Community,

I need your help please,

I have a Gallery where I want to only show the current Item (ID), is there a way to achieve this so that I don't have to see all items?

 

Any guidance would be appreciated,

Thank you

Claire

1 ACCEPTED SOLUTION

Accepted Solutions
SanCForer
Frequent Visitor

Hi @ClaireAllen 

Following @lenro you can try:

 

Filter(DataSource, Value = YourID)

 

- DataSource= the name of your data set or sharepoint list

- Value = the name of the field you whant to filter in this case "ID"

- YourID = The ID you want to show

 

View solution in original post

5 REPLIES 5
lenro
Helper III
Helper III

Hi @ClaireAllen ,

 

In the gallery you should write a formula

Filter(CollectiionName,Value="YourID")

Hi @lenro ,

I can't seem to get this to work

Filter(DataSource, Value = Your ID)

 

I don't have a collection name, I'm using my Datasource Name i.e. my SharePoint list Name and what is Your ID? is it just ID number, or ThisItem.ID??

Sorry this is new to me so still learning the formula's within Power Apps.

Thank you for your assistance,

Kind regards

Claire

 

Hi @ClaireAllen ,

Then I need the whole story to understand.

 

You have a SharePoint list, where you have a column with ID? And you want to show only this ID in gallery right?

 

But is your SharePoint consist only on one ID? Or you know that it will always be the same ID, let's say 123456?

SanCForer
Frequent Visitor

Hi @ClaireAllen 

Following @lenro you can try:

 

Filter(DataSource, Value = YourID)

 

- DataSource= the name of your data set or sharepoint list

- Value = the name of the field you whant to filter in this case "ID"

- YourID = The ID you want to show

 

View solution in original post

Thank you @SanCForer 

To help others, the formula I entered as you suggested - Filter(COI, ID = Gallery1.Selected.ID)

I then added a Label to Show the Current ID Reference, to make sure that I was seeing the current ID - "Form ID: " & ThisItem.ID

 

Thank you @lenro for the guidance,

Regards

Claire

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

PA Community Call

Power Apps Community Call

Next call is happening on April 21st at 8a PST.

MBAS Carousel

Sign up for our May 4th event!

May the fourth be with you, join us online!

secondImage

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (58,351)