NI Home
Cart Cart | Help
Hello Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI
You are here: 
NI Home > NI Developer Zone > NI Discussion Forums


Reply
Member
dslemusp
Posts: 19
0 Kudos
Accepted Solution

How to put a Group property in a Curve Related Text label with Curve Expansion

[ Edited ]

Hi

 

I am working on a Graph which Plots a WaveFormChannel named "Test". Since I have activated the curve expansion, the graph shows all the Channels named "Test" within the DataPortal. Now I want to put the value of the group property "MyGroupProperty" in the legend, so every time I add a new group, automaticaly add the new signal "Test" and show "MyGroupProperty" in the legend.

So far I tried to use the curve related text in the label option, with something like this

 

@GroupPropGet(GroupNumber,"MyGroupProperty")@, but I have to give the value of GroupNumber, and then it shows the same value for all the signals. So If I add a new group to the dataportal with a channel Test, The legend will show the label of the new signal but, the MyGroupProperty remains as the same for all the labels

 

 

Doubt.JPG

 

 

Thanks in advance for your help

Trusted Enthusiast
Brad_Turpin
Posts: 2,389
0 Kudos

Re: How to put a Group property in a Curve Related Text label with Curve Expansion

Hi dslemusp,

 

You can use the global variable "CGI" in a DIAdem expression to supply the Current Group Index of the curve being plotted (even in expansion mode).  I prepared an example for you that shows this and attached it below.

 

Brad Turpin

DIAdem Product Support Engineer

National Instruments

Member
dslemusp
Posts: 19
0 Kudos

Re: How to put a Group property in a Curve Related Text label with Curve Expansion

Thank you Brad, It worked

By using this web site, you accept the Terms of Use for this web site. Please read these Terms of Use carefully before using any part of this site. Please go here for information on ni.com's copyright infringement policy.
My Profile | Privacy | Legal | Contact NI © 2011 National Instruments Corporation. All rights reserved.    |    E-Mail this Page E-Mail this Page