Jump to content

Is library part of another library


Recommended Posts

I'm trying to find out if a given library is part of another libary. I don't get anything sane to work.

For a VI there is a 'Library' property that returns the owning library reference. For a library such feature does not exist.

Even stranger is that the 'Localized Name' or 'Display Name' only contain the bare name of the library.

I currently have one workaround:

post-2399-1237497387.png?width=400

And this solution needs any VI to be inside the lvlib root-folder.

Ton

PS this code needs to be done in 8.2 so any ideas?

Edit:

Darren Twittered

QUOTE

@tonplomp If you have the library's ProjectItem, you can get Parent in a loop until you hit a target or a library.

So I builded the following project setup:

post-2399-1237499305.png?width=400

The 'Untitled 4.vi' has the following contents:

post-2399-1237499402.png?width=400

Note that the Parent's ref of the folder is not valid! Somehow the folder inside the top-level library has no valid parent :(

Ton

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.