web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : SA43OOSMPYWMI6RSurytZu
Power Apps - Building Power Apps
Unanswered

Collecting a sequence of days

Like (0) ShareShare
ReportReport
Posted on 6 Oct 2021 13:42:07 by 2

I have the following formula to collect each day and its next day. The problem I am having with this is the 'Value' seems to be the number of iterations it has passed through the sequence. This means if the first day displayed by the calendar is not the selected month then it will bleed into the wrong dates. I tried fixing this by simply copying and pasting the formula for calculating each 'Value'.

 

I feel like if PowerApps had breakpoints like coding with C# in Visual Studio then I would be able to have a breakpoint to check what values are being passed into the filter. I have no idea why but as far as I know there is no feature for this. Does anybody know a way around this or a way to debug the values other than sticking them in a gallery that displays them?

 

Code:

UpdateContext(
{
colDays: ForAll(
Sequence(42),
{
Value: varFirstDayOfMonth + Value - 1 - Weekday(
varFirstDayOfMonth,
StartOfWeek.Sunday
) + 1,
NextDay: varFirstDayOfMonth + Value - 1 - Weekday(
varFirstDayOfMonth,
StartOfWeek.Sunday
) + 2,
EventsOnThatDay: Filter(collectionOfEventsOnThatDay, Value = EventDay)
}
)
}
);

 

 

 

Thankyou

I have the same question (0)
  • JR-BejeweledOne Profile Picture
    5,836 Moderator on 08 Oct 2021 at 13:18:30
    Re: Collecting a sequence of days

    What are you trying to accomplish?   I have built a few calendars that show events on certain days, so maybe I can help if you tell me what you ware wanting to do.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 686 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 433 Super User 2025 Season 2

#3
wolenberg_ Profile Picture

wolenberg_ 266 Moderator

Last 30 days Overall leaderboard