Reputation: 569
I have a piece of code that clears a collection when the Powerapp/Properties Panel of a Sharepoint Online Document List is opened.
Right, now the onVisible only runs the first time I open the Panel. If I close it and open another document with it, the onVisible does not run again.
Essentially, looking for a way to detect if a new Document Properties Panel has been opened and run a bit of code.
I don't believe ContextVariables work either, as it is the same App/Same Screen that opens.
Is there a way to detect a change to the "Panels" Input ID variable perhaps? Is there a way to detect if the "record" the Panel just opened changes? (OnSuccess doesn't seem to catch it)
Any thoughts would be appreciated. Thanks
Upvotes: 0
Views: 663
Reputation: 569
While does doesn't answer the onVisible exactly, I created two different workarounds.
Option 1: Use a Timer to check the ID of the sharepoint list item, and compare every x seconds.
Option 2: Reset the variable on the OnSuccess of the Form Control and also on the OnCancel of the App Control. (Recommended)
Upvotes: 0