02-09-2010 01:55 PM
Intaris wrote:This "Index Vals" approach ONLY works RELIABLY if there is only one array element visibly on the Array control / Indicator.
Otherwise clicking on any array element besides the first one before running the VI will return false values.
Shane.
It will for the most part return the value in the top left position of the control. That is why Andrey second example does not work (there is only one refence and it only point to the top left item).
Re: the Strict type
You can try making it non strict but you are still coding up a cluge to adhear to C concepts. Its time to "go with the DATA flow."
Ben
09-10-2012 09:31 AM - edited 09-10-2012 09:32 AM
@Andrey_Dmitriev wrote:
Hi, Will,
Not fully understand what you need, but you can get reference to array element by according property node:
but you will be not able to get array of refences of the elemenths, because you have only one.
For example: this code looks the same but will not work:
Andrey.
Hi.., As it is a constant, its okay.. But, when it is a Control, if the active index (the array element that v have clicked with mouse cursor or edited at last) is not the 0th Index, then I couldn't get the Reference of all the array elements in order., I am missing few elements due to the above problem. I am using the method which you have describes., so pls guide me how to overcome this issue..
Thanks in Advance..!!
09-10-2012 10:36 AM
@Ben wrote:
Re: the Strict type
You can try making it non strict but you are still coding up a cluge to adhear to C concepts. Its time to "go with the DATA flow."
Ben
I agree wth Ben. It sounds like you are trying to do things like you would if you were using C. LabVIEW is a data flwo language and it would be in your best interest (and everyone that touchs the code after you) that you learn how to use data flow correctly. Otherwise you are basically trying to fit round pegs into square holes.
10-18-2020 06:00 PM
Hi Guys,
This is my first post/question on the forum, so please forgive any obvious bone headed questions.
I'm not happy that I can't use the blinking attribute on an individual element in an array of booleans... and maybe I'm not the only one. So I've been monkeying around trying to get a color box blinker arrangement that could be used instead... this suggested by others.
I've got an actor set up to blink a CB. It's working the way I want and can control the Fgd, Bgd and blink rate, etc. Among other things, I pass this actor a ref (that it uses to access the CB it's blinking).
My problem right now is that I need to pass the actor a ref to a single CB that's in an array. I found posts that show how to get a pointer to an array element (seems like excessive work, but hey).
Question:
What is the symbol (I've tried to find it!) that is converting the loop variable to the input to IndexVals?
Thanks in advance for your help.
-Dave
10-18-2020 06:32 PM
The function between the i for the loop and Index Values is "Build Array".
But your VI still not going to do what you want it to do. "Index values" sets which element is shown in the upper right hand corer.