LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Programmatically change "Legend:Plots Shown" property

I am trying to change the value of the "Legend:Plots Shown" within a labview (7.1) program. I have three plots on a waveform chart stacked on top of one another (entered via a 2d array). I get an error message every time I run the vi which I don't understand:
"Error 1000 occurred at Property Node (arg 1) in legend.vi"

I have enclosed the vi FYI
Any help would be appreciated

Martyn
0 Kudos
Message 1 of 6
(3,343 Views)
Hello Martyn

That error means the property node you are using is only valid for "overlay plots" and not for "stacked plots".
Anyway, if you keep it, right click on the property node and check "ignore errors inside node". It will do nothing but your vi will run whithout that annoynig error.

Most of these errors can be avoided if going to Tools>Options and uncheck "enable automatic error...". But this can be dangerous.

Hope it helps.
Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
Message 2 of 6
(3,343 Views)
Is there anyway of programatically controlling the number of stacked plots displayed in a waveform chart?

Martyn
0 Kudos
Message 3 of 6
(3,343 Views)
Hi again, Martyn

The only way I know is using a cluster to the chart. Stacked plots adapts automatically to the number of inputs to the cluster. And, in this case, you can select the number of legends to display. Courious, isn´t it?
Ok. Se attached your vi for clusters and this link about the subject.

http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=135&HOID=50650000000800000068A70000&UCATEGORY_0=_49_%24_6_&UCATEGORY_S=0&USEARCHCONTEXT_QUESTION_0=stacked+plots&USEARCHCONTEXT_QUESTION_S=0

Cheers
Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
0 Kudos
Message 4 of 6
(3,343 Views)
Sorry, I forgot other way

See this NI example for a dinamic way of displying stacked plots.

http://sine.ni.com/apps/we/niepd_web_display.DISPLAY_EPD4?p_guid=B123AE0CB938111EE034080020E74861&p_node=DZ52038&p_submitted=N&p_rank=&p_answer=&p_source=External

Cheers
Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
0 Kudos
Message 5 of 6
(3,343 Views)
This works only for waveform graphs, the same logic will not work on a waveform chart..

Martyn
0 Kudos
Message 6 of 6
(3,343 Views)