cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
pmroz
Super User

Hyperlinks in data table?

Hello all,

Is there a way to put web URLs into a table such that they are clickable (i.e. act as hyperlinks)?

We have data tables that are extracts of data from a web-based system. The users would like to be able to click on a row of data in JMP and bring up the page in the web-based system for the "case" that they clicked on.

I know what the URL is supposed to be for each row, and I can simply call web(url) to bring up the page. But, I want the users to have an easy (=transparent) way of drilling down on a particular case.

I think I can do something clever using the approach used by Ian Cox in his neat example from the file exchange called actionOnRowSelect.jrn. The problem is that sometimes the users create distributions from the data and they could click on a distribution bar that represents thousands of rows of data. I don't want to bring up a thousand pages at once - just one.

Thanks,
Peter
1 ACCEPTED SOLUTION

Accepted Solutions
dave_matthews1
Level III

Re: Hyperlinks in data table?

Hyperlink usage in column text is a new feature in JMP 14.0.

 

You can find more information about here in the JMP 14 Help about Hyperlinks to Text Columns.

View solution in original post

6 REPLIES 6

Re: Hyperlinks in data table?

I think that the principles of Ian's code would be the starting point. The script that is launched could check the number of selected rows, and contain logic to do nothing unless the row launching the script was the first in the list of selected rows
pmroz
Super User

Re: Hyperlinks in data table?

OK I'm getting closer. I have a table with a column containing the following formula:

If(Selected(Row State(Row())), Eval(Parse(Web(:Script))))

The Script column contains the URL for each row.

To avoid opening up too many Internet Explorer windows, I'd like to check the number of selected rows and just open up the URL for the first one. The code for that would be something like:



The problem is that I can think of several scenarios where the current data table is not the one containing the web links. For example if you create a summary table that will be linked back to the original table.

How can a formula for a given table determine the number of selected rows it contains?

Thanks,
Peter

Re: Hyperlinks in data table?

I've just tried the following code as a formula within a table:



Current Data Table gets correctly resolved even if you make the selections from a linked table - I tried what you suggested with the summary table.

Actually this works better when the selection is made from a summary table, because only a single selection occurs. If you select the rows from the original table or from something like a scatter plot, then as each row is selected the script re-executes ... so whilst it only prints the 1st row of the selection, the print occurs multiple times. Not figured out how to solve that yet.

As a separate issue, around usability. Having a URL launch automatically with a selection might interfere with other usages in JMP (i.e. will there be times where a user wants to make selections but not want windows popping up?) One approach would be to have a table script called something like "launch URL" which would run the same piece of code. It means an extra click for the user, but they get to launch the URL based on selections only if they want the URL. It also solves the problem I described earlier, and more generally, it would allow you to present a list if multiple rows are selected
pmroz
Super User

Re: Hyperlinks in data table?

Got something working. Not sure I'll use it, but it's interesting nonetheless. The following formula loads up a list with selected rows, and when it hits the bottom of the table just uses the first one in the list.



I will not be taking this approach because it will interfere with how people are using this table. Instead I'll be building a dedicated dialog box that they can launch from.

Thanks to Geoff Mann for helping me on this one. Thanks for your help too _Stig_.

Regards,
Peter

Re: Hyperlinks in data table?

I've been playing around with the issue of dealing with multiple row selections. I've posted some sample code on the file exchange. The script runs against the table Movies that is available in the sample data.

http://www.sas.com/apps/demosdownloads/jmpFileExchange_PROD__downarea.jsp?productID=110310&jmpflag=Y
dave_matthews1
Level III

Re: Hyperlinks in data table?

Hyperlink usage in column text is a new feature in JMP 14.0.

 

You can find more information about here in the JMP 14 Help about Hyperlinks to Text Columns.