cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JR-BejeweledOne
Super User
Super User

Gallery Template Fill based on date lookup part 2

I have a calendar gallery and a gallery of events.    There are date values to compare in both the calendar gallery and the event gallery.  StartDate and EndDate are not text values, they are date values, so there is no need to wrap them in DateValue().

 

This works beautifully. 

 

 

 

If(
     LookUp(GalleryHolidaysOtherEvents.AllItems, StartDate = DateValue(LabelAprilDateOE.Text), true), 
     Style.DayBG, 
     White
    )

 

 

 

Some events are multi-day.   I have both a Start Date and an End date.  However neither of these work.   There are no errors and single day events where the day that matches the start date is filled appropriately, but the end date and the days in between are not filled and multi-day events do not have any days filled..

 

 

 

If(
     LookUp(GalleryHolidaysOtherEvents.AllItems, (StartDate >= DateValue(LabelAprilDateOE.Text) && EndDate <= DateValue(LabelAprilDateOE.Text)), true), 
     Style.DayBG, 
     White
    )

 

 

 

 

 

If(
     LookUp(GalleryHolidaysOtherEvents.AllItems, StartDate >= DateValue(LabelAprilDateOE.Text) && EndDate <= DateValue(LabelAprilDateOE.Text), true), 
     Style.DayBG, 
     White
    )

 

 

 

Any ideas?



If you like this post, give it a Thumbs up. If it answered your question, Mark it as a Solution to enable other users find it.
1 ACCEPTED SOLUTION

Accepted Solutions
v-bofeng-msft
Community Support
Community Support

Hi @JR-BejeweledOne :

Please try:

 

 

If(
LookUp(GalleryHolidaysOtherEvents.AllItems, (StartDate <= DateValue(LabelAprilDateOE.Text) && EndDate >= DateValue(LabelAprilDateOE.Text)), true),
Style.DayBG,
White
)

 

Best Regards,

Bof

View solution in original post

2 REPLIES 2
v-bofeng-msft
Community Support
Community Support

Hi @JR-BejeweledOne :

Please try:

 

 

If(
LookUp(GalleryHolidaysOtherEvents.AllItems, (StartDate <= DateValue(LabelAprilDateOE.Text) && EndDate >= DateValue(LabelAprilDateOE.Text)), true),
Style.DayBG,
White
)

 

Best Regards,

Bof

I FINALLY figured that out yesterday.   Just hadn't had time to come back and update this.

 

Thanks!



If you like this post, give it a Thumbs up. If it answered your question, Mark it as a Solution to enable other users find it.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on June 15, 2022 at 8am PDT.

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Top Kudoed Authors
Users online (1,882)