Jump to content

Accessing elements in a large array without manipulating all the array


tomasl

Recommended Posts

Hi,

I have a large 2D array of strings (let's say 2x1000000). When i need to access only a few elements of the array it takes quite a lot of time. Is there anything to access those elements directly without manipulating all the array? (something like pointers in C++).

Thank You very much.

T.

Link to comment

Try the In Place Element Structure to modify a single element of an array efficient. Array Subset and Replace Array Subset can also be efficient when used correctly.

An array of strings in LabVIEW is basically an array of pointers to strings; since strings are not fixed-size they cannot be stored in the array itself and so the array stores pointers to strings instead. String manipulation is often slow because the string may need to be reallocated as it grows.

Link to comment

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.