Hello! I have a table in a data source that has a date column. Any given date may or may not have a row associated with it.
Then I have a canvas app with a DatePicker and an associated form, Form1. I want to be able to select an arbitrary date, and if there's already a row in the data source for that date, I want to put the form in view (or potentially edit) mode; if not, I want to put the form in new mode.
How can I do this? Thanks!
(One path I've considered is setting an onchange handler on the DatePicker which would look something like "If(Form1.ThisItem, ViewForm(Form1), NewForm(Form1))" but a) ThisItem doesn't seem defined in this context and b) there's no guarantee that the load status would be accurate at control change time.
Another that seems more "Power Apps-y" would be to set a property such as Form1.Mode to If(Form1.ThisItem, FormMode.View, FormMode.New) and let the responsive engine do its thing, but I can't seem to find such a property...)