Viewing swp files without opening them in SolidWorks
Viewing swp files without opening them in SolidWorks
Hey all,
I'm retiring in the 2nd quarter and want to document all my macros for future usage.
Is there a way to view the contents of a swp file without opening it in SolidWorks?
That would make the process a lot more efficient.
Thanks!
I'm retiring in the 2nd quarter and want to document all my macros for future usage.
Is there a way to view the contents of a swp file without opening it in SolidWorks?
That would make the process a lot more efficient.
Thanks!
- AlexLachance
- Posts: 2179
- Joined: Thu Mar 11, 2021 8:14 am
- Location: Quebec
- x 2361
- x 2011
Re: Viewing swp files without opening them in SolidWorks
Microsoft Visual Studio should do the trick.
Edit: forgot to mention, if those SWP are for SolidWorks macros, then most likely you will require a SolidWorks licence or the person who uses the macros to open them in vB so that they can load the SolidWorks references.
Edit: forgot to mention, if those SWP are for SolidWorks macros, then most likely you will require a SolidWorks licence or the person who uses the macros to open them in vB so that they can load the SolidWorks references.
Re: Viewing swp files without opening them in SolidWorks
Thanks.AlexLachance wrote: ↑Tue Jan 10, 2023 9:04 am Microsoft Visual Studio should do the trick.
Edit: forgot to mention, if those SWP are for SolidWorks macros, then most likely you will require a SolidWorks licence or the person who uses the macros to open them in vB so that they can load the SolidWorks references.
image.png
I'll look into that.
Re: Viewing swp files without opening them in SolidWorks
I'm not sure what you mean by "Document all your macros for future usage"...
Why not just take the .swp files themselves? What is the value of having access to the code if you don't have SolidWorks? It's like having a set of car keys but no car.
Why not just take the .swp files themselves? What is the value of having access to the code if you don't have SolidWorks? It's like having a set of car keys but no car.
Re: Viewing swp files without opening them in SolidWorks
I believe OP wants to check and document what each macro does for making it easier to use.
Deepak Gupta
SOLIDWORKS Consultant/Blogger
SOLIDWORKS Consultant/Blogger
Re: Viewing swp files without opening them in SolidWorks
So... Just the time savings of double-clicking a file in Explorer vs going to Tools->Macro->Edit and viewing in the VBA editor? I don't think you're going to find anything more efficient than mapping Edit to a SW shortcut key. I've not tried it myself (Maybe @AlexLachance has verified?) but I'd be a bit surprised if even visual studio can open .swp files any easier than SW can.
- AlexLachance
- Posts: 2179
- Joined: Thu Mar 11, 2021 8:14 am
- Location: Quebec
- x 2361
- x 2011
Re: Viewing swp files without opening them in SolidWorks
I haven't tried it myself but one of my collegues which works both on the ERP and sometimes on macros for us has used it to edit macros in the past. I think he's trying to create/edit macros without having SolidWorks.josh wrote: ↑Tue Jan 10, 2023 12:25 pm So... Just the time savings of double-clicking a file in Explorer vs going to Tools->Macro->Edit and viewing in the VBA editor? I don't think you're going to find anything more efficient than mapping Edit to a SW shortcut key. I've not tried it myself (Maybe @AlexLachance has verified?) but I'd be a bit surprised if even visual studio can open .swp files any easier than SW can.
- Frederick_Law
- Posts: 1945
- Joined: Mon Mar 08, 2021 1:09 pm
- Location: Toronto
- x 1636
- x 1467
Re: Viewing swp files without opening them in SolidWorks
Save them out as text.
Re: Viewing swp files without opening them in SolidWorks
Unfortunately I've been less than diligent about cleaning up bits and pieces in my macro folder. You know record some things, use some of the recording, never delete the recorded file.
I wound up opening every swp file, some 40+ of them, and whittled them down to about 10 which are actually useful.
Then I created a OneNote notebook with a listing of them and description of what they do for the "lucky" stiffs who follow behind me.
Thanks!
I wound up opening every swp file, some 40+ of them, and whittled them down to about 10 which are actually useful.
Then I created a OneNote notebook with a listing of them and description of what they do for the "lucky" stiffs who follow behind me.
Thanks!