VBA - Retrieve the link of a selected part in an assembly

Hello

And is it possible to retrieve the link of a selected part in an assembly?

Merco for your help:)

1 Like

Hello

What a link???

Hello

Do you want it in a variable?

You can take inspiration from this code:

http://www.lynkoa.com/tutos/macro-ouvrir-la-piece-dans-l-assemblage

And you will have to use the GetTitle statement you know:)

 

See also this tutorial:

http://www.lynkoa.com/tutos/import-export-formats-neutres/macro-solidworks-obtenir-le-nom-du-fichier-s%C3%A9lectionn%C3%A9

 

1 Like

Or it is recorded!

 

 

1 Like

Here's how to do it without VBA (2 clicks)


recuperer_le_lien_dune_piece_selectionnee_dans_un_assemblage.docx

@ac: the goal is to use it in a macro probably!