How can I manage if I have a start date (date picker) and must be added to this.
For example my first date is 12/07/2021. After this, the following dates should be generated automatically.
So first + 1 day then +14, days. then again + 1 day and again 14, etc. and that in a set of 16x (see picture)
I have the following Collection
ClearCollect(DateRanges,AddColumns(firstN([0,1,14,15,28,29,42,43,56,57,70,71,84,85,98,99],DateDiff(DatePicker1_1.SelectedDate, DatePicker2_1.SelectedDate, Days) + 1),"day","Day" & (Value + 1),"date",
DateAdd(DatePicker1_1.SelectedDate, Value, Days)
My question is how can I write the dates in a SQL database.Database is called cycleDate column fields are, date1, date2, date3 to date16
Hope you can help me.
You're going about it the right way for your purpose.
In the button OnSelect I would also add a Notify("Dates added") so the user knows it has worked. Without a confirmation they might press the button multiple times and add multiple sets of records.
Finally, you might want to wrap your Patch() in an IfError() so you can control what happens if the patch doesn't work properly.
Good luck with your project!
Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.