LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to highlight a specific element of an array

Almost 10 years later...

I guess there's is still no way to get programmatically the reference of a specific array element?

I mean not just the last by user clicked array element, but any element selected by its index(es).

Thanks for help if there is an option without dll calls

0 Kudos
Message 11 of 14
(1,162 Views)

The way this works makes me think of the Slide Markers, there you also can't get the reference of a specific Marker value (Min or Max), and always get the last clicked, and can't get programmatically a specifically desired reference. 

0 Kudos
Message 12 of 14
(1,155 Views)

Hi David,

 

in an array all elements share the same properties, they only differ in value.

So there is still only one reference for an array element available (and needed)!

 

Why do you need a reference to a specific array element? What are you trying to do?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 13 of 14
(1,146 Views)

Thanks Gerd for trying to help me.


I'm aware that most properties of an array element are common for all elements, that's also the essence of an array of course, else it would be a cluster. But for the user interface behavior you might still want to treat one specific array element, examples are e.g. Hightlight, Blink, Background Color etc.

 

If I could implement Labview, I could imagine some kind of hybrid approach: There are all the properties that are common to array elements, and if these properties are set, they apply for all. Then if I want to set a property which is possible to set per array element like Hightlighting or Blinking, there should be a way to select that element programmatically with e.g. an array as Index selector. If another property which is global is set, the index selector is simply not taken into account.

 

In my case in the meantime I realized that it's a different story. I have an array of cluster, a cluster which contains booleans, a string and a digital. All digitals in my software have enhanced usability, where Key and Mouse Scroll behavior is treated in a custom way. I gather all references at initialization to register events dynamically. This is possible for all Digitals (native, Digital Displays of Slides, Knobs, Digitals, in Clusters etc.) except for some cases e.g. Slide Markers which are not real Digitals but where I want this enhanced behavior, too. For those Slide Markers i need to handle the reference differently, by registering the event only after user selection of the specific array element, else i might get the wrong reference. It seems to me now, that for my purpose this is also the way I should treat Digitals in an array or Digitals in an element e.g. cluster as array element.

0 Kudos
Message 14 of 14
(1,138 Views)