08-04-2008 03:52 PM - edited 08-04-2008 03:55 PM
08-05-2008 02:11 AM
08-05-2008 02:47 AM
My old tic tac toe example shows how to determine which square of a 2D array has been clicked.
http://forums.ni.com/ni/board/message?board.id=170&view=by_date_ascending&message.id=247044#M247044
You probably can adapt some of it for the arrays on the right. If the array can be scrolled, you also need to account for the "indexvals" offset.
The Layers controls is easiest, because you only show one element. Just read the "index vals" property to get the array element and parse the coordinates to get the cluster element.
btw: the small while loop on the right serves no purpose at all and acts just as a CPU burner. You can delete it without any change in functionality. Is there anything else to it?
08-05-2008 02:47 AM
08-05-2008 10:47 AM
mikeporter wrote:
You can set up a Value Change event on the entire array and then use the NewVal and OldVal nodes in the event structure to determine which element exactly has changed. In this situation, the OldVal node will contain the contents of the array before the event and the NewVal node will contain the contents of the array after the event.
08-08-2008 02:14 PM
08-19-2008 02:41 AM - edited 08-19-2008 02:48 AM
Hi again everyone,
When I was almost done implementing my numpad popup, I ran into one more issue. I'm able to bring up numpads for numfields in arrays, but not for the index display of the array. Any ideas how to solve this? I've attached a VI named "Layer Setup," which shows how I bring up a numpad for a numfield inside an array. It brings up the numfield from the correct index as well.
Thanks,
Kunal
08-25-2008 08:32 PM
Any thoughts on the hit test or getting an event listener on the index (or "dimension") value of an array?
Kunal
08-27-2008 10:55 AM
Hi bhatiak,
Using mostly your code, here is an example showing how to get your popup for an array index. (The example is written in LabVIEW 8.5.1 since your popup subVI didn't like me trying to save it in version 8.0.)
Regards,
Kevin S.
Applications Engineer
National Instruments
08-27-2008 05:03 PM
Ahh - I see what I missed. Didn't quite know what to do with the array to get the index value. Thanks for the help Kevin!
Kunal