cancel
Showing results for
Did you mean:

## Change Date Picker Default Date

Hi,

Is there a way to change the Date Picker Default Date?  What I would like to show as the default date is the current date plus 5 business days.  Is this possible?

Joe

1 ACCEPTED SOLUTION

Accepted Solutions
Super User

Here's a formula that will calculate todays date + 5 business days.

``````With({ startDate:Today(),
},
Switch(Weekday(startDate, StartOfWeek.Monday),
)
)``````

I have a post that describes how this formula works.

http://powerappsguide.com/blog/post/formulas-how-to-cope-with-weekends-public-holidays-in-date-calcu...

Also, you might consider voting for my idea here to include a built-in function to calculate business days.

9 REPLIES 9
Dual Super User

Set the default date property of the control to:

hope it helps !

Super User

DefaultDate:

Today() + 5

------------

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

Thank you very much for your help.   🙂  Your formula works great but I need to only count business days and not weekends.  Is that possible?

Thank you very much for your help.   🙂  Your formula works great but I need to only count business days and not weekends.  Is that possible?

Super User

Check this tutorial from Reza Dorani:

https://youtu.be/QVvhDe6puq0?t=31

------------

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

Super User

Check this tutorial from Reza Dorani:

https://youtu.be/QVvhDe6puq0?t=31

------------

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

Super User

Here's a formula that will calculate todays date + 5 business days.

``````With({ startDate:Today(),
},
Switch(Weekday(startDate, StartOfWeek.Monday),
)
)``````

I have a post that describes how this formula works.

http://powerappsguide.com/blog/post/formulas-how-to-cope-with-weekends-public-holidays-in-date-calcu...

Also, you might consider voting for my idea here to include a built-in function to calculate business days.

Thank you very much for your help.   🙂

Thank you so much for your help.  Impressive code and works awesome!  Thank you again!

Announcements

#### Power Apps News & Announcements

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

#### Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

#### Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (5,218)