Page 1 of 1
Carryover of saved custom views
Posted: Sat Jun 01, 2024 12:48 am
by Petertha
I just installed SW24 SP2.0 so going through the exercise of creating fresh Part, Assembly, Drawing & Sheet templates. I'm noticing a quirk that I have seen before on prior versions, but was not expecting it now because I was used fresh templates from 2024 download. I know from past experience if you use an older template on a newer install, potential for funky things can happen as things change over time. But the only attribute I changed on the new SW24 template thus far from download version was make the units MMGS & a few minor dashboard features.
So I built an assembly from Parts (which all used v2024 Parts templates). But when I went to Views, it displayed some saved views I recognize from one of my v2021 assembly models. I was able to delete them with the red X & they didn't re-appear post-save, but just wondering why they are there to begin with? When I open the Assembly template itself I cant see any associated views.
Is it one of those procedure things where I should first make an assembly from a random part, delete any unwanted rouge views, then save that with the assembly file type & it holds those view settings? (Kind on analogous to how you first need to load a Part into a new Drawing template in order to extract linked Part attributes - but when you save as Drawing template, the part evaporates).
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 8:45 am
by Glenn Schroeder
Some settings are "sticky," as opposed to be saved in templates. I suspect that's what you ran into here.
By the way, I know some people advocate for new templates with every release, but I've been using SW since 2009, and I've never started new ones from scratch. They don't even get saved to the current version unless I make changes.
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 10:00 am
by brandonklar
Glenn Schroeder wrote: ↑Mon Jun 03, 2024 8:45 am
....I know some people advocate for new templates with every release....
I wouldn't say I advocate for them, but our VAR used that specifically as a copout for an issue that we began having a while back (I think that one we were having issues with feature names not being persistent through different configurations). It seemed like an easy excuse they could make for just about any issue in order to close out a service ticket, so now we update every few releases at least.
I'm jealous you've had better luck.
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 11:08 am
by Frederick_Law
I think there is a way to show hidden views in drawing.
Select and delete them.
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 12:58 pm
by JSculley
I believe you are talking about the saved views here:
- image.png (15.17 KiB) Viewed 1870 times
These saved views aren't saved in the templates. You will see the same list of saved views in parts and assemblies.
They are stored in the registry:
Computer\HKEY_CURRENT_USER\Software\SolidWorks\SOLIDWORKS 20xx\User Interface\Saved Views
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 1:49 pm
by TTevolve
JSculley wrote: ↑Mon Jun 03, 2024 12:58 pm
I believe you are talking about the saved views here:
image.png
These saved views aren't saved in the templates. You will see the same list of saved views in parts and assemblies.
They are stored in the registry:
Computer\HKEY_CURRENT_USER\Software\SolidWorks\SOLIDWORKS 20xx\User Interface\Saved Views
I believe it is a list of one that you have created in the past, it's not attached to the template.
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 2:14 pm
by DanPihlaja
Are you talking about these views?
If so, those come from 2 sources:
1) the canned views from here:
- image.png (18.66 KiB) Viewed 1852 times
2) And also all annotation views that are listed for the part:
- image.png (19.17 KiB) Viewed 1852 times
It lists them both.
Re: Carryover of saved custom views
Posted: Mon Jun 03, 2024 8:41 pm
by Petertha
JSculley wrote: ↑Mon Jun 03, 2024 12:58 pm
I believe you are talking about the saved views here:
image.png
These saved views aren't saved in the templates. You will see the same list of saved views in parts and assemblies.
They are stored in the registry:
Computer\HKEY_CURRENT_USER\Software\SolidWorks\SOLIDWORKS 20xx\User Interface\Saved Views
Yes, exactly. That user defined view flyout that you show. I went to my (new install) 2024 folder area & did not see that particular \user interface\ subfolder. Maybe I'm in the wrong area? I still have v2021 installed until & similarly could not locate by clicking or Ctrl-F.
Re: Carryover of saved custom views
Posted: Tue Jun 04, 2024 7:22 am
by JSculley
It's not a folder on your hard drive. It is an entry in the Windows Registry.
Re: Carryover of saved custom views
Posted: Tue Jun 04, 2024 11:10 am
by CarrieIves
@JSculley - Thanks for sharing that it was a registry setting. I have noticed that sometimes those views are there and was wondering how they appeared. It must be a newer thing. I don't think I noticed it until we were using SW2023.
Re: Carryover of saved custom views
Posted: Tue Jun 04, 2024 12:15 pm
by JSculley
CarrieIves wrote: ↑Tue Jun 04, 2024 11:10 am
@JSculley - Thanks for sharing that it was a registry setting. I have noticed that sometimes those views are there and was wondering how they appeared. It must be a newer thing. I don't think I noticed it until we were using SW2023.
I'm using SW2017, so it's been there since at least then.
Re: Carryover of saved custom views
Posted: Tue Jun 04, 2024 8:57 pm
by Petertha
JSculley wrote: ↑Tue Jun 04, 2024 7:22 am
It's not a folder on your hard drive. It is an entry in the Windows Registry.
I see, thank you. My knowledge level just tapped out with those words so I consulted with Gemini. This looks like something I could manage to really screw up. Chimpanzee with a loaded weapon syndrome LOL. Just out of morbid curiosity, can you provide a bit more detail of how you went about getting to registries? Now these views obviously belong to some old models, it wouldn't be the end of the world if the view files got properly deleted & the old model didn't show them anymore. Would it be that easy or would SW flag some kind of error & create more headaches? Now if I uninstall SW-2021 (likely where they originated) does that uninstall also clean out registries built by that version? Or its parts of SW detritus that seems to accumulate over the years?
My Q) how do I go to a registry setting on my Win-10 PC in order to delete a file
Gemini A) Modifying the registry to delete a file on Windows 10 is generally not recommended. It's a complex process with some risk of causing system instability if you make a mistake. There are safer and easier ways to achieve this. Here's a recommended approach:
- Uninstall the program: If the file is associated with a program, uninstalling the program through Settings > Apps & features is the safest way to remove it. This will also remove related registry entries.
- Use File Explorer: If the file itself is visible in File Explorer, you can simply delete it like any other file.
If you're absolutely set on using the registry.... {more stuff}
Re: Carryover of saved custom views
Posted: Wed Jun 05, 2024 7:56 am
by JSculley
Petertha wrote: ↑Tue Jun 04, 2024 8:57 pm
I see, thank you. My knowledge level just tapped out with those words so I consulted with Gemini. This looks like something I could manage to really screw up. Chimpanzee with a loaded weapon syndrome LOL. Just out of morbid curiosity, can you provide a bit more detail of how you went about getting to registries?
https://learn.microsoft.com/en-us/troub ... nced-users
Now these views obviously belong to some old models, it wouldn't be the end of the world if the view files got properly deleted & the old model didn't show them anymore.
Deleting the saved views (by clicking the red X in the Orientation dialog box will not affect any drawings or models that use them. There's really no need to edit the registry for this. Just delete them using the Orientation dialog box and then exit SOLIDWORKS so that the changes are saved in the registry.
Re: Carryover of saved custom views
Posted: Wed Jun 05, 2024 1:45 pm
by gupta9665
I often run into this issue and now planning to make a macro to delete all the named views. May further enhance the macro to show the list and let the user select the one he/she desires to delete.
Re: Carryover of saved custom views
Posted: Thu Jun 06, 2024 4:46 am
by gupta9665
Here are the quick codes to delete all named views int he active model file. No error handling has been added.
Code: Select all
Option Explicit
Dim swApp As SldWorks.SldWorks
Dim swModel As SldWorks.ModelDoc2
Dim vModelViewNames As Variant
Dim i As Long
Dim Errors As Long
Dim Warnings As Long
Sub Main()
Set swApp = Application.SldWorks
Set swModel = swApp.ActiveDoc
vModelViewNames = swModel.GetModelViewNames
For i = 0 To UBound(vModelViewNames)
swModel.DeleteNamedView vModelViewNames(i)
Next i
swModel.Save3 swSaveAsOptions_Silent, Errors, Warnings
End Sub