Dates in an InfoPath repeating table without weekends
In this InfoPath 2010 demo you will see how you can automatically populate a repeating table control on an InfoPath 2010 form with dates that are sequentially incremented thereby skipping any dates that fall in weekends.
The technique discussed in recipe 65 of InfoPath 2010 Cookbook can be expanded upon and implemented in many different InfoPath solutions that require you to manipulate dates without writing code.
The following video is a demonstration of how you can use rules, functions, and formulas in InfoPath 2010 to create a solution where whenever a user clicks to add a new row to a repeating table, the date picker control that is located in the new row of the repeating table is automatically populated with a date that is one day after the date in the previous row of the repeating table.
And if the date in the new row of the repeaing table falls on a Saturday or Sunday, those two dates are skipped and instead the date for the Monday thereafter is displayed in the date picker control.
In this InfoPath 2010 demo video, you saw that...
- You can have a date picker control automatically display and increment a date by one day when a row is added to a repeating table.
- You can skip the dates for weekends while adding rows to a repeating table on an InfoPath form.
- You can disable a date picker in a repeating table as soon as the repeating table contains more than one row.
See more InfoPath 2010 tutorial videos »
Copyright: This article may not be used on web sites (whether personal or otherwise), copied, disseminated, altered, printed, published, broadcasted, or reproduced in any way without an expressed written consent of S.Y.M. Wong-A-Ton. The techniques demonstrated in this article may be used within any Microsoft InfoPath project. This article is provided without any warranties. Copyright for this article is non-transferrable and remains with the author, S.Y.M. Wong-A-Ton.