Show if based off of action button pressed

Hi everyone,

Is it possible to have two actions that do the same thing (edit this row) but have one provide different reults for a columns show_if?

I have one action that allows an edit on the data shown, which is heavily reduced to not see anything unless it is relevant. But I want the other action to edit the row but while showing all content. To allow adding content to the one row.

Essentially. How would I refer to the action that was used to get to the view from within a show_if expression? Unless theres another way of getting the same result.

There’s no way to determine the result f a Show_If expression from another expression.

If I’m interpreting your situation correctly, I encourage you to consider using a slice for one of the views. You could then use the slice itself to hide columns, or you could use the CONTEXT("View") in your Show_If expressions to target one view or the other.


Sorry my original question must’ve been difficult to interpret.

I wanted to write in the show_if expression if the user hits action one they are sent to a form view that allows them to edit the columns they could see from the detail view in which the action was. If the user hits action two they are sent to a form view of that row but can see all columns and edit them.

Slices wont work for this from my understanding because almost all of the columns have a show if based on their data, I cant just remove columns within the slice.

the CONTEXT(“View”) seems like the most likely solution but both actions lead to the same view name.

@Steve is correct. The best way to handle your need is with separate Slices and Views.

You certainly CAN remove unnecessary columns from a Slice…that is the main use of Slices. Each Slice is treated as its own datasource. Columns NOT included will NOT execute their expressions when the row is acted on. To contrast what mean, if a column IS included BUT is hidden, its expressions still fire when the row is acted on.

Where things get a bit tricky, is when you include columns in different Slices/Views but want different Show_If behavior. This is when CONTEXT() function comes in handy.



Ok so from my understanding I should use the CONTEXT() function. In order to make use of this I need to set the actions up so they send the user to different views in order for CONTEXT to work correctly.

When doing this I cant find a way to send a user to a specific view AND edit the row they were looking at. Sending the user to a specific form view seems to lose its row value, and using _THISROW for the row value doesnt work either. Any ideas?

Use LINKTOROW() with a form view as the view target:


Do all the user see exactly the same columns in your detail view? If Yes, I believe the most appropriate solution is what @Steve had already proposed. Create a slice of your table containing only the columns that you show in your Detail View (include the Key column as well) and assign a ref type Form View to this slice. And with the 1st action call this form, and with the 2nd action call the table’s default form:

Action 1

LINKTOROW([_THISROW], "Your_Form_View_Name_For_Slice")

Action 2

LINKTOROW([_THISROW], "YourTableName_Form")

Yes all users see the same data, some columns are hidden because the data is irrelevant. The app is for inspections and the ones to ignore are sections that have passed. I only need to see columns that have failed and their accompanying column which is data on why it failed.

Thanks guys, It works as you can see in the attachment.

I ended up using the one slice, creating two views and an action connected to one of those views.
The show_if in each column now relies on the context()