onse
onse

Reputation: 23

Block diagram function to duplicate y-axis in LabVIEW

I am trying to make a dynamic XY-graph in LabVIEW, in which I'd like to be able to set a number of y-axis during execution. I have so far found only the "mouse-clicky" version of duplicating a y-axes, i.e. right-clicking it on the front panel etc. Is there a way to do this during execution, via a property node or similar?

Upvotes: 0

Views: 389

Answers (2)

Fourier
Fourier

Reputation: 111

You cannot add and remove scales programmatically. But you can hide/show existing scales. So you should configure a preset list of scales, then show/hide them according to your needs.

Here is an code snippet. Drag and drop the picture in your block diagram in order to have the ready to use code.

enter image description here

Upvotes: 0

What i would do is to create the amount of Y axis i know a user could use. For example; if you know user could need two Y axis in the application, right click on the Y axis in the chart and duplicate it. This will create two axis in your application with indexes 0 and 1.

Then by using property nodes you can select the index of the active Y scale, and make it visible or invisible in runtime.

Upvotes: 1

Related Questions