Jump to content
Sign in to follow this  
chris754

Array Events - Bug or Expected Behavior?

Recommended Posts

(If this is not the right forum, please move as appropriate)

 

Yesterday, I was trying to capture the "key down?" event on a string array control. I noticed that the event would never get fired while typing into one of the strings in the array. The event does fire if you type in the index control of the array. My question: Is this expected behavior or a bug? After trying a few things, I can get the behavior I want by getting a reference to the "ArrElem" and registering it for the "key down?" event and passing the into the dynamic event terminal. This is fine for my purposes and will implement my code in this fashion. However, I certainly was not expecting this event to behave in this way. I guess I could see why this may be the case (you are typing into a string control, not an array) but curious what other people think...

 

This was all done in LV2013.

 

Thanks!

Share this post


Link to post
Share on other sites

I can understand why you would think that way, and users would probably generally want the function to work that way.  But by the rules of LabVIEW, when you register for an event on the array, you are registering on the array control, not on the control within the array control, that is a different reference and it seems you've found how to get at that reference.

Share this post


Link to post
Share on other sites

Yes, I did find that reference. I could make an argument either way. It was just different than what I expected and was curious what others thought.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.