Directly reference hyperlink formula from Row Action

Hi,

I’m trying to add a redirect to a row action within a table that opens up a new tab to view a PDF that we currently uploaded as a static resource.

I’m thinking this would typically just be an action type of ‘Redirect to URL’ that would need to be added to the Row action, however, we have an additional layer of complexity.

There are 2 separate documents that a user can be directed to based on the value of a particular field. We are currently using a formula field which evaluates the value of the field and displays a hyperlink to one of the documents when the page loads depending on the value of the field. If I add the field to a page I just see the URL displayed. I don’t want to include it in a pop up tied to a row action because I don’t want the user to have to click twice, instead I’d like the formula to be evaluated when the user clicks the row action and then the user is automatically directed to the new browser tab/document URL based on the formula out put.

Any help on this would be greatly appreciated. Thanks!

Just make your hyperlink be “/{{Your_Formula_Field}}” . Skuid should automatically get the right row.

Thanks Moshe for your help on this.

I have tried the following based on your suggestion:

 - Added a Row action to my table
 - Set the Action Type to ‘Redirect to URL’
 - Added my formula field to the URL field as "/{{My_Formula_Field}}"

However, when testing this out I’m being redirected to a new page with the following error message:

URL No Longer Exists. You have attempted to reach a URL that no longer exists on salesforce.com

Do you have any ideas what might be going on here?

Did you replace “My Formula Field” with the actual API name of your field? If that doesn’t work then post the URL in the address bar that shows after you get redirected.

Hi Moshe,

Yes I did pate the API name into the URL field. As I mentioned above though, the issue that I’m having is with the formula field. The formula field needs to be evaluated upon click of the row action and then based on the formula output, the user should be directed to one of 2 different URL’s. So unfortunately it’s not as simple as pasting the address URL into the Skuid URL field.

Do you have any suggestions on how we might be able to get this to work?

Thanks for all of your help on this. it is much appreciated!

If the evaluation needs to happen client side,  you will not get much love from a formula field. This is because the formula field will only be evaluated on page refresh from the server.  I’d reccomend that your row action run a snippet where the evaluation occurs and a window.location method is executed to the correct approrpriate URL.