Sending data to a screen on navigation

I have a handful of screens where each screen is a different view of the same table data.

I had a single “editor” screen, whereby I’d click a data-row from one of the views, it would navigate to the table, and the data-row could be edited and saved from the “editor” screen.

BUT, as far as I know, a screen cannot receive generic data. The “editor” screen is directly linked to just ONE of the view screens and specific controls from that screen. That means that each view screen will need to have its own corresponding editor screen. I would need many many duplicates of the exact same screen to accomplish this.

If I were building a regular website, I’d use POST to send data to a single template/module page. Is there a similar capability here?

I also tried this, and did not get it to work:

  • In the screen actions, add an action for screen_close to set a variable
  • read the variable in the next page to get the data

It’s not clear if screen_close is triggered on navigation? I’m using the tablegrid “on row selection navigate to page” function.

I also tried to use the “Actions > row_select” for the tablegrid to “set variable” and then “navigate” but the “navigate” does not work. Presumably it is being overridden by the built-in function in a tablegrid to control what happens when a row is clicked.

Hi Marc,

Screen Close action of the current screen triggers when you redirect from the current to another screen. Using a variable on Screen Close action should work. Looks like some logical or configuration issues due to which it might not be working for you.

As you have mentioned different views, there must be some logic behind it like users from different groups will be redirected to a different view or some other similar logic.

In this case of users from different groups, you can set the desired value in a variable on the corresponding view’s screen close action. Now use an IF() condition in the corresponding controls of your Editor screen and take reference of respective controls from different views screens based on the value of this variable.

You can use this IF() condition in the desired controls by going to its Data section > Custom Formula. It is similar to a simple IF() function used in excel. You can know more about Custom Formula here.

Here is a quick sample. Let’s assume I have 3 controls (on the same or different screens) named View1, View2, and View3. Based on the user group set in the variable, I want to take reference these 3 controls in a text input (on the same or different screen) named “Final Result”.
This is how the formula of this text input control named “Final Result” will look like:

In case you are using the row_select action to set data in the variable & navigate to another screen, ideally, you should change the On Row Click property of the action from Navigate with selection to Select Row. Also, keep the set variable task either on row_select action or on Screen Close action to avoid any conflicts.

I hope this clarifies your doubts. :slightly_smiling_face: