web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Global variable trigge...
Power Apps
Answered

Global variable triggering on opening form

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi,

 

I have built a custom form from a SharePoint list that includes a cascade drop down (using managed metadata). 

 

In the first column of the cascading dropdown the OnChange is

Reset(DataCardValue9);Set(resetkeytarget,"Yes")
 
In the second column of the cascading dropdown the DefaultSelectedItems is
If(resetkeytarget="Yes",Blank(),Parent.Default)
 
The FormScreen OnVisible is
Set(resetkeytarget,"No")
 
I have also set all the SharePointIntegration actions & the App OnStart to
Set(resetkeytarget,"No")
 
The cascade functionality works fine and the data is written to SharePoint list perfectly
BUT when I open the form in SharePoint from an existing row/item (sorry not sure on my terminology here) the value in the second column of the dropdown shows for a second then dissappears. Oddly when I close the form and open it again the value is there.
I can repeat this for other items with the same effect or if I refresh the SP List it also happens.
 
Any help would be very much appreciated.
Categories:
I have the same question (0)
  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi, 

     

    I appear to have stumbled into a solution to my own problem (oh the irony two days of struggle and when I post the problem I then find the solution). Anyhow it is here.

     

    https://powerusers.microsoft.com/t5/Building-Power-Apps/Global-or-context-variable-unchanged-if-page-not-refreshed/m-p/140570

     

    I removed Set(resetkeytarget,"No") from each of the SharePointIntegration Actions and added 

    Navigate(FormScreen1, ScreenTransition.None) to OnEdit, OnView and OnNew
     
    It appears to be working fine and thank you to all you kind people out there posting helpful stuff.

     

  • alrezac Profile Picture
    Microsoft Employee on at

    Hi,

     

    Thanks for your follow up post! I am glad you were able to get this resolved on your end. Hopefully this will prove useful for future communities users.

     

    Regards,

     

    Alex

     

    -------

     

    Community Support Team _ Alex Rezac
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 329 Most Valuable Professional

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 179

Last 30 days Overall leaderboard