Community
Vault Customization
Share your knowledge, ask questions, and explore popular Vault API, Data Standard, and VBA topics related to programming, creating add-ins, or working with the Vault API.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Identify a link when this one is selected in a search results window

2 REPLIES 2
Reply
Message 1 of 3
adubois
169 Views, 2 Replies

Identify a link when this one is selected in a search results window

adubois
Contributor
Contributor

Hello,

I am looking for a way to identify a link in a search results window. In the example below, I have two links that are in two different folders. When I use Context.CurrentSelectionSet.ToList(), a list of ISelection of SelectionTypeId.File is returned in this case (the base file information is returned). So I can't tell which of the two links is selected.

 

Context.NavSelectionSet.ToList() does not seem to be useful in this case.

 

Alex.

adubois_0-1681731273473.png

 

0 Likes

Identify a link when this one is selected in a search results window

Hello,

I am looking for a way to identify a link in a search results window. In the example below, I have two links that are in two different folders. When I use Context.CurrentSelectionSet.ToList(), a list of ISelection of SelectionTypeId.File is returned in this case (the base file information is returned). So I can't tell which of the two links is selected.

 

Context.NavSelectionSet.ToList() does not seem to be useful in this case.

 

Alex.

adubois_0-1681731273473.png

 

2 REPLIES 2
Message 2 of 3
adubois
in reply to: adubois

adubois
Contributor
Contributor

I think I found an old thread talking about this and there is still no workaround. (2015)

 

-->"Unfortunately i'm not aware of any possibility at this time to know wether the object you selected is a link or the object it self. From an API point of view it's always the object, never the link, but in some cases, like yours, it would be interesting to know wether it's a link or an object.
so, as for now, i don't think there is a way to figure this out. I would place a support request through ADN in order to get this as an API wish for a next Vault release."<--

0 Likes

I think I found an old thread talking about this and there is still no workaround. (2015)

 

-->"Unfortunately i'm not aware of any possibility at this time to know wether the object you selected is a link or the object it self. From an API point of view it's always the object, never the link, but in some cases, like yours, it would be interesting to know wether it's a link or an object.
so, as for now, i don't think there is a way to figure this out. I would place a support request through ADN in order to get this as an API wish for a next Vault release."<--

Message 3 of 3
adubois
in reply to: adubois

adubois
Contributor
Contributor

I was finally able to achieve my goal by displaying a dialog box after right-clicking in the folders context menu and launching FindFilesBySearchConditions and FindLinksBySearchConditions to list Files and Links of the folder. I can then make something of listed links.

0 Likes

I was finally able to achieve my goal by displaying a dialog box after right-clicking in the folders context menu and launching FindFilesBySearchConditions and FindLinksBySearchConditions to list Files and Links of the folder. I can then make something of listed links.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report