Jump to content

[CR] Array Point to RowCol


Recommended Posts

index.php?automodule=downloads&req=display&code=sst&id=11

File Name: Array Point to RowCol

File Submitter: dsaunders

File Submitted: 3 Aug 2006

File Updated: 22 Oct 2006

File Category: User Interface

Converts a pixel coordinate to an array index. Returns an array of indices with a length equal to the number of array dimensions. Also returns if the point is within the content rectangle (not on the caption, scrollbars, etc.)

Works on any N-dimensional array regardless of visibility of caption, label, index display, or scrollbars. Designed to be used on mouse events that provide the mouse coordinates.

Limitations: Property nodes do not indicate the array border width, nor if the user has chosen to display an element gap. These inputs are thus provided on the VI.

Click here to download this file

Link to comment
David,

Great VI!

One comment: I think that the GObj.OwningVI property generates (opens) a new VI reference and should therefore be closed, after one's done using it.

Cheers,

-Jim

Good eye. I had a subVI to handle the panel defer, and obviously didn't check the new code quite enough. I will update the VI.

David Saunders

Link to comment
  • 14 years later...

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.

×
×
  • Create New...

Important Information

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