Page 1 of 1

Cleaning up projects after the dust has settled

Posted: Fri Feb 25, 2022 8:07 am
by bentlybobcat
We're kinda a custom design shop, where large scale assemblies seldom get reused. Parts, yes, large assembles, virtually never.

Compounding this is we use sub-contractors to do some design for us, whose files get included in the "big mess".

We (me...) have come across a lot of bad practices, natch, and most of them are fairly easily rectified.

The one that is challenging us (me...) at present are suppressed restraints in assemblies.

What we (I) are running into are restraints that are not used anywhere that come back to haunt you... Meaning they are suppressed but flag an error when an assembly is opened.

I've tried the "purge features" command and it kinda, sorta works, but not particularly reliably and certain doesn't parse the assembly removing the ghosts from all the parts and assemblies.

I've put this in API, because methinks this is going to have to be a macro.

I've got some routines in my pocket which will parse the assembly. This is straightforward.

Once I have a file open and activated, any idea how would I go about deleting the ghost restraints?

Thank you

Re: Cleaning up projects after the dust has settled

Posted: Fri Feb 25, 2022 8:27 am
by berg_lauritz
I think this:
https://www.codestack.net/solidworks-ap ... -features/

could help you find those leftovers, I think.

Re: Cleaning up projects after the dust has settled

Posted: Fri Feb 25, 2022 11:23 am
by bnemec
Do I understand correctly that you want to delete all assembly mates that are suppressed in all configurations? Any other qualifications that would prevent the mate from being deleted?

Re: Cleaning up projects after the dust has settled

Posted: Fri Feb 25, 2022 2:15 pm
by bentlybobcat
bnemec wrote: Fri Feb 25, 2022 11:23 am Do I understand correctly that you want to delete all assembly mates that are suppressed in all configurations? Any other qualifications that would prevent the mate from being deleted?
That's basically correct.

I've got assemblies with mate after mate after mate that has been suppressed, and new mates added. o[

Don't really know how to answer your second question