How to open a specific layout in another screen

you can use this block :
blocks

What is the start value? how to use it?

You can use the hide button and use it

Make the Block like this :

On Screen1 Create Like this :
blocks
On Screen2 Create Like this :
blocks

1 Like

Till yesterday I was able to use "Open another screen with start value" button today morning it stopped working... please help


^screen 1

image
^screen 2

These things stopped showing effect
Also now even if I click any button, the title.text is always "bird"... If the bird block is removed everything else stops happening...

use Do it to debug your blocks, see also tip 4 here https://puravidaapps.com/learn.php
especially in your case: what is the value of the global variable mapping? how can you be sure, that these blocks do not open screen information several times?

see also Live Development, Testing, and Debugging Tools
Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun.

This makes no sense at all.

  • You ignore other button handlers by not checking the notAlreadyHandled value.
  • You ignore the component value, instead of using it as the lookup index into the 4 button components you set up as keys in the lookup table (name them like buttons, please)
  • You try to open the information screen 4 times, regardless of which button is pressed.

P.S. Sorry, Taifun, you buried the lede.

Ha ha... I missed the global variable... it was right there...

more valuable feedback now: :wink:

  1. the second item of a pair never is the text "mainmenu", so the if part never will be executed...
    usually you would use a MainMenu button handler for this assuming you have a button MainMenu in your project
  2. don't use a for each in list loop, try the loopup in pairs block to get the screen name you are looking for together with the key component
    How does the lookup in pairs block work?

see also this example A Multiple Choice Quiz: How to work with the advanced features

Taifun

I want to use Any Component block to:

  • There are 8 buttons in a vertical arrangement on screen 1.
  • When a button is clicked, it has to open screen 2, and in screen 2, open a specific vertical arrangement and also calls a specific function that renames labels and changes images in respective placeholders.
    *for eg: IF I CLICK THE DOG BUTTON ON SCREEN 1, IT OPENS SCREEN2 AND THEN IN THAT, OPENS THE "DOG" VERTICAL ARRANGEMENT, ALSO IN THAT VERTICAL ARRANGEMENT, IT HAS TO CALL A SPECIFIC FUNCTION, THIS FUNCTION RENAMES A LABEL TO "DOG" AND IN THE IMAGE PLACEHOLDER, CHANGES FROM THE USUAL IMAGE TO DOG IMAGE...

Please help, I need to complete this project very soon,
Thanks in advance

You can do this using start value.

how? i cannot figureout? please help... I shalll be thankful

Let's say if someone clicks on ButtonA then any button click will give ButtonA as component.
Now if component == ButtonA then open another screen with start value A.
On Screen2, if start value is A then hide all arrangement and set Arrangement A to visible.

1 Like

Can i use a list to get Button A or Button B? If yes, how?

Can you please roughly show the blocks?

I merged all your three topics together since they are related. Please stay with your topic instead of opening a new one.


I put this on the first screen
image

This on the second screen,

the button takes me to the right place , but as stated does not change title.text to dog... please help, I am probably having some trouble with start value...

You are sending a component as string and comparing it with a string.
Just set label.text to start value and you will know the reason.

So what am I doing wrong and what am i supposed to be doing?

image
Nothing happens, same result... I cannot figure it out...