Read filename and folder

Library for macros
sloworks
Posts: 31
Joined: Tue Mar 23, 2021 12:24 pm
Answers: 0
Location: Finland
x 6
x 19
Contact:

Read filename and folder

Unread post by sloworks »

Hi, small addition to my macros/add-ins

This one reads active documents folder, filename and both and you can copy them to clipboard. I use it often for example with "save as to not native format" or when I have to email the full path to someone. GetDamnPathAndName.swp

All my SW-stuff and link to downloads:
https://sloworks.fi/muut/
pois1.png
BR
Markku
www.sloworks.fi
User avatar
gupta9665
Posts: 420
Joined: Thu Mar 11, 2021 10:20 am
Answers: 25
Location: India
x 438
x 459

Re: Read filename and folder

Unread post by gupta9665 »

Thank you for sharing.
Deepak Gupta
SOLIDWORKS Consultant/Blogger
User avatar
Fabrizio_T
Posts: 3
Joined: Thu Nov 21, 2024 2:18 am
Answers: 0
x 3

Re: Read filename and folder

Unread post by Fabrizio_T »

Dear Sloworks,

I hope this message finds you well.
I wanted to take a moment to express my gratitude for the wonderful macro you shared.
It truly inspired me!
I've made a few slight modifications to tailor it to my needs, allowing me to copy the same data from the selected component. As a mechanical designer and not a programmer, I acknowledge that the code I've produced might not be particularly polished, but I'm pleased to say that it works!

Thank you once again for your valuable contribution. Your work has made a significant impact on my project.

Best regards,
Fabrizio
Attachments
Path con UserForm.swp
(74.5 KiB) Downloaded 53 times
sloworks
Posts: 31
Joined: Tue Mar 23, 2021 12:24 pm
Answers: 0
Location: Finland
x 6
x 19
Contact:

Re: Read filename and folder

Unread post by sloworks »

Hi, nice version. Did not understand probably all of it because the language thought :-)

It's quite annoying that SW does not give any really good way to get those names and paths...and when you get annoyed, you go and automate the damn thing so you never have to worry again :-)
BR
Markku
www.sloworks.fi
User avatar
AlexLachance
Posts: 2226
Joined: Thu Mar 11, 2021 8:14 am
Answers: 17
Location: Quebec
x 2419
x 2061

Re: Read filename and folder

Unread post by AlexLachance »

"Get Damn Path and Name" as a macro name made me chuckle :lol:
sloworks
Posts: 31
Joined: Tue Mar 23, 2021 12:24 pm
Answers: 0
Location: Finland
x 6
x 19
Contact:

Re: Read filename and folder

Unread post by sloworks »

Faster version. Closes after you press one of the 4 buttons.
Attachments
GetDamnPathAndName.swp
(53 KiB) Downloaded 153 times
BR
Markku
www.sloworks.fi
Post Reply