From 11:00 PM CDT Friday, Nov 8 - 2:30 PM CDT Saturday, Nov 9, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can not add new plot name into legend of XControl Waveform Graph

Hello,

I created a simple XControl which contains Waveform Graph.
When I use this XControl_Graph.xctl in Example.vi I can not add new legend item by typing its name into uninitialized legend element (see picture below).

Screenshot.png

 


This behavior differs from behavior with normal Waveform Graph as well as from behavior in Facade,vi of XControl_Graph.xctl.
Does anybody know why?
Second question: Is it possible to ensure that user can add new legend item of XControl_Graph.xctl in "normal way"?

Thank you very much for any help.

Best regards,

Martin

0 Kudos
Message 1 of 4
(3,097 Views)

Your XCTL is technically running at this point.  It is like if you had a normal graph on a running VI.  You can't add more plots to the graph while it is running.  That is an edit-time operation.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 4
(3,087 Views)

Thank you very much for your reply.

 

I observed that new plot can by added by clicking on the small picture in uninitialized legend element (see picture below).

Screenshot2.png

 

Is it possible to prohibit this way of adding a new plot?
I tried to catch the Graph: Plot Attribute Change event in Facade.vi but it seems that adding new plot in this way does not fire this event.

Thanks a lot.

Martin

0 Kudos
Message 3 of 4
(3,076 Views)

Hello mavlc!

 

I think there is no direct method to see if you add plots, but there is a workaround that you can use. If you put in a property node of the graph and you read the value, you get it back in an Array format, there you can check the size of the array and detect if there is a change in that number.

 

I hope this helps with your problem.

Best Regards,
Levente
0 Kudos
Message 4 of 4
(3,050 Views)