cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Piter_D
Responsive Resident
Responsive Resident

Taking only specific values ​​from the gallery

Hi, I have a question because in the gallery it filters a certain number of dates for a given item, and unfortunately for some items there are dates in the form of 01/01/1900. Unfortunately, I cannot restrict the display of these dates by the condition of type date <> date (1900.01.01). the question is if I can write some type condition if subtitle1 = 01/01/1900 then take the next value in the table and let it work as a loop.

Piter_D_0-1641971471104.png

@Pstork1 @timl @WarrenBelz 

1 ACCEPTED SOLUTION

Accepted Solutions
rubin_boer
Super User
Super User

@Piter_D using the gallery as a source, try adding a label to the app and set the

 

I assume this

rubin_boer_0-1641973756069.png

 

 

"Earliest date for dates without 01/01/1900" text = 

Text(
    Min(
        Filter(
            YourGallery.AllItems,
            yourDateColumn> DateValue("01/01/1900", "en-US")
        ),
        date
    ),
    "mm/dd/yy"
)

 

Hope it helps 

R

hey there if you liked the post give it a thumbs up, and if it solved your question please accept it as a solution.

View solution in original post

9 REPLIES 9
rubin_boer
Super User
Super User

hi @Piter_D , what is it you are trying to achieve when you say "take the next value", do you wish to summarize values etc?

hey there if you liked the post give it a thumbs up, and if it solved your question please accept it as a solution.

I want to take the earliest date from this gallery except 01/01/1900. that is, the one marked with a bird from the photo.

Piter_D
Responsive Resident
Responsive Resident

or maybe i can filter this gallery on another gallery and then write condition where subtitle1 <> 01/01/1900?

rubin_boer
Super User
Super User

@Piter_D using the gallery as a source, try adding a label to the app and set the

 

I assume this

rubin_boer_0-1641973756069.png

 

 

"Earliest date for dates without 01/01/1900" text = 

Text(
    Min(
        Filter(
            YourGallery.AllItems,
            yourDateColumn> DateValue("01/01/1900", "en-US")
        ),
        date
    ),
    "mm/dd/yy"
)

 

Hope it helps 

R

hey there if you liked the post give it a thumbs up, and if it solved your question please accept it as a solution.

Text(
    Min(
        Filter(
            Gallery1.AllItems,
            Subtitle8.text > DateValue("01/01/1900", "en-US")
        ),
        date
    ),
    "mm/dd/yy"
)

i have a error in "Min" function.

rubin_boer
Super User
Super User

Replace Subtitle8.text is of type text and the date is type date, hence the error. you can use the column name or DateValue(Subtitle8.text, "en-US")

hey there if you liked the post give it a thumbs up, and if it solved your question please accept it as a solution.

still get error in Min() and what is "date" in this formula? is not recognized.

rubin_boer
Super User
Super User

yourDateColumn

hey there if you liked the post give it a thumbs up, and if it solved your question please accept it as a solution.

okay, its work thank you 😄

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.

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 (3,121)