I'm new to Powerapps so still doing stoopid things and finding much weirdness.
I have a datepicker as part of a gallery. The gallery is connected to a local collection. A new row in the collection is "Collect"ed by a button.
Behind the datepicker OnChange event is...
... where timesheet is the collection and TSdate the field i'm updating.
This works, but does NOT update the displayed date. It continues to display the default - "today()". If I then select the SAME date it displays correctly.
Without the OnChange event the displayed date updates to date selected in the picker calendar correctly.
It is kinda like triggering OnChange causes Powerapps to "forget" to update the display. (I guess that when I select the SAME date again there is no OnChange triggered)
The only other code is behind the OnSelect event - Select(Parent)
I'm sure i'm being daft here, but I just cant seem to figure it out!
Can you please share the following additional details:
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."
items = timesheet //Ie just the raw local collection
There is no separate label control, the datepicker is part of the gallery and the date is displayed by that. As far as I can see there is no text attribute of a date picker, only SelectedDate. It's not a selectable attribute or event in the editor so there is nothing behind it that I can see.
Thanks for replying!
Just in case anyone else has the same issue and stumbles across the thread..
I never found a solution to this so I ended up moving all the editing capability out of the gallery and into separate controls. Not quite as neat, but hey, Powerapps is at it's best when you need something quick and can accept that you have to do things its way or no way.
Check out the on demand sessions that are available now!
Stay up tp date on the latest blogs and activities in the community News & Announcements.
Features releasing from October 2020 through March 2021
Check out the Power Platform Community Highlights