I have a gallery with icons that have their visibility set using a Switch function and rules.
I know that rules are being depreceated but these don't seem to be the root of the issue
Something like this:
ico_cross : Visibility :
FormPage1, If( rule_FormPage1 = true, false, true ),
FormPage2, If( rule_FormPage2 = true, false, true ),
FormPage3, If( rule_FormPage3 = true, false, true )
This works fine in the currently published version which is using 3.19104.33.
I went to edit the app today and noticed that the Switch is no longer working this is using releasr 3.19111.26.
I removed the rules and replaced them with a test condition as so:
ico_cross : Visibility :
FormPage1, If(1+1=2 = true, false, true ),
FormPage2, If(1+1=2 = true, false, true ),
FormPage3, If(1+1=2 = true, false, true )
Still the switch did not work.
I changed the Switch to and Or with nested If statements as follows:
If(ThisItem.Screen = FormPage1, If(rule_FormPage1 = true, true, false)),
If(ThisItem.Screen = FormPage2, If(rule_FormPage2= true,true,false)),
If(ThisItem.Screen = FormPage3, If(rule_FormPage3= true,true,false))
And this works, correctly.
Has something happened to the Switch function?
Hi, my app is having the exact same issue since the new PowerApps release. I'm glad someone else found the common root cause.
I was using a series of conditions that determined what the next screen would be, and using a switch statement to navigate to the screen. This has stopped working and I've been going crazy trying to fix this.
Would love to have a MS response to this.
Do you mean that you can not use Switch function about Screen?
I've made a similar test but not met the same problem.
I set the gallery's arrow button's OnSelect:
It will navigate to screen correctly.
Here's my PowerApps version: 3.19111.28
I suggest you clear your browser's cache, update to the latest version, try this again by using the latest version of PowerApps.
If the problem still exists, I suggest you ask for help here:
Hi @v-yutliu-msft thanks for your response, but this bug is present when the switch statement happens on the screen control. In your example you have the switch on ThisItem.Name.
If you look at @digiservice's switchfunction.png screenshot, you can see how you can replicate this error. I've replicated this myself on a simple test app.
Edit: FYI current PowerApps release for my test app = 3.19111.33
Hey folks, I created an app that demonstrates the problem + the If workaround, and submitted a ticket (case 119111723000225).
I also noticed another issue related to this - if you store the screen control as a global variable and browse the Variables tab to see its current value, it appears with blank details.
FYI for others who may be encountering issues. There is another bug related to using screen controls in operator statements:
DOES NOT WORK
ScreenVariable in [‘Screen1’,’Screen2’,’Screen3’]
Or(ScreenVariable = ‘Screen1’,ScreenVariable = ’Screen2’,ScreenVaraible = ’Screen3’)
Check it out!
Fill out a quick form to claim your user group badge now!
Find out where you can attend!
Features releasing from October 2019 through March 2020
The largest Power BI, Power Platform, and Data conference in New Zealand