Conditional: How to judge on what screen are you on
-
Roman MoraruHas successfully completed the online course Basics (100)2 years ago #34300
Hello,
in process designer if you were to implement an conditional that is supposed to check, on what type of screen are you, how can you do it?
Problems: The URL doesn’t change it’s structure from screen to screen, so how can you judge on what screen are you on?
Jennifer HäfnerHas successfully completed the online course Intermediate (200)Has successfully completed the online course Advanced (300)Has successfully completed the online course Basics (100)Has successfully completed the online course Advanced (310)Has successfully completed the online course Advanced (320)Has successfully completed the Intermediate CertificationHas successfully completed the Advanced Certification1 year ago #34302::Hi Roman,
For that purpose, you could create a new Global Variable where you store the current screen name. For example, when navigating to the screen ‘Details’, add a UI action shape to the navigation process, where you set the value of the Global Variable to the constant ‘Details’.
When doing this with every screen navigation, the Global Variable always contains the current screen.
Then, for your condition to check the current screen, you can use a condition shape and compare the Global Variable to the screen names.
I attached screenshots of the suggested implementation. I hope this helps!
Attachments:
You must be logged in to view attached files.Armin WinklerHas successfully completed the online course IntroductionHas successfully completed the online course Intermediate (200)Has successfully completed the online course Advanced (300)Has successfully completed the online course Basics (100)1 year ago #34331::Hi Roman,
adding to Jennifer’s reply: Inside of script activities you can also check for the current screen via this code statement: ‘this.getView().getId()’ Please note, however, that if you are subscribing to widget events fired from a popup context, this statement will return the ID of the screen on top of which the popup was opened instead of the popups screen.
Kind regards,
Armin
You must be logged in to reply to this topic.