LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to get plot names from cursors

Solved!
Go to solution

Hi,

Is it possible to get name of plot where the cursor currently is? If yes - how?

Regards

Mike

0 Kudos
Message 1 of 5
(2,367 Views)

You only need use property node: Plot>Plot name

 

Best regards

0 Kudos
Message 2 of 5
(2,330 Views)
Solution
Accepted by topic author MeeHow

Hello Mike and Mahu!

 

To get name for the plot with cursor is associated with migt be little more complicated than mentioned here, but not much.

 

1) First find out which cursor you are working with, and set it active. (might be irrelevant for you)

2) Get index of plot associated with active cursor

3) Set active plot to be the one you found out

4) Use property node mentioned by Mahu to get active plot name

 

get_plot_name_for_cursor.png

 

I have also attached simple example for you here.

 

 

Regards,

Stefo

Certified-LabVIEW-Developer_rgb.jpg

Message 3 of 5
(2,311 Views)

Hi Stefo,

thanks for your solution:)

Can you explain how can I make it proof for errors I mean when I have 2 plots, and I switch off that one where cursor is, there is an error:(

 

0 Kudos
Message 4 of 5
(2,301 Views)

you need to manually check what plot you are setting to be active - its index can't exceed the maximum number of plots - 1.

 

The best error checking is to manually check if the index of plot you try to work with is smaller then number of plots displayed.

 

 

regards,

stefo

Certified-LabVIEW-Developer_rgb.jpg

0 Kudos
Message 5 of 5
(2,286 Views)