LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Displaying URL in tree

Hello Everyone,
 
              I need to display URLs / web links in tree. When the user selects a particular web link it should open that web link in a seperate window. How can this be done?
 
Thanks,
Vasanth.
 
Ya Ya
0 Kudos
Message 1 of 6
(3,369 Views)
All the column items in the particular column will be links only. So, if I could just make all the entries for that column (by setting some property to the whole column) to display underlined, that would be enough to appear it like a link. Any suggestions for that?
 
Thanks,
Vasanth.
Ya Ya
0 Kudos
Message 2 of 6
(3,367 Views)
Vasanth,

I would use a Property Node to set the Cell Font to be underlined and blue.  Then if you want the links to be launched in the default web browser when clicked I would suggest using an event structure coupled with the Open URL in Default Browser VI (which you can find here: Functions»Dialog & User Interface»Help»Open URL in Default Browser.vi).

The end result would look something like this:



I hope this helps you get started,

Simon H
Applications Engineer
National Instruments
http://www.ni.com/support/


Message Edited by Simon H on 01-17-2007 07:15 PM

Message Edited by Simon H on 01-17-2007 07:16 PM

Message Edited by Simon H on 01-17-2007 07:17 PM

Download All
Message 3 of 6
(3,352 Views)

Simon,

        Thanks for your suggestion. The vi you suggested for opening the link in the browser worked fine but I could not set the cell properties to make it appear as a link because I am using LabVIEW 7.1. Sorry I did not mention this before. Is there a way to display it in the same way as you did in LabVIEW 8.2?

 

Thanks,

Vasanth.

Ya Ya
0 Kudos
Message 4 of 6
(3,334 Views)
Vasanth,

I don't believe you can set a cell to be underlined programmatically in LabVIEW 7.x.  If this tree is populated prior to run-time you could change the font settings manually (by selecting each cell and pressing Ctrl+0 to bring up the font dialog box).

You can however change the color of the text using the Active Cell Properties»Foreground Color property.

Regards,

Simon
0 Kudos
Message 5 of 6
(3,320 Views)

Simon,

        Thanks. Ok then, I will display the links as plain text and inform explicitly that it is a link.

Thanks,

Vasanth.

Ya Ya
0 Kudos
Message 6 of 6
(3,311 Views)