There are two types of tickets in my list, and since content type isn't currently accessible in PowerApps (Microsoft admits a bug on this one), I am simply storing a hardcoded text value instead of the content type name and reading from that field to perform my logic. If the user clicks on item of type A then I want it to show the Type A display form, etc.
For the sake of illustration, let's say we have two items on the list, one of type A and one of type B.
Here's how it's currently flowing when the user performs these actions in sequence:
1) User clicks on item A, Home screen opens. (Should be View Type A screen) 2) User clicks on item A again, View Type A screen opens. (This is correct) 3) User clicks on item B, View Type A opens but with item B data. (Clearly wrong) 4) User clicks on item B again, View Type B opens with item B data (this is correct)
In all cases, whenever a screen is opening, it first displays the last-shown screen for a split second and then switches to the one it's really trying to display.
This is the code in my SharePointIntegration.OnView:
Switch(SharePointIntegration.Selected.'My Text Field', "Type A", ViewForm(frmViewTypeA);Navigate(ViewTypeAScreen), "Type B", ViewForm(frmViewTypeB);Navigate(ViewTypeBScreen))
It feels to me like something isn't getting cleared or reset properly, but I don't know where else to look or what I'm looking for.
Thanks very much