Page 1 of 1

How to improve the speed of SW selection API

Posted: Wed Feb 16, 2022 9:42 pm
by ZSJ
How to improve the speed of SW selection API?
Or To avoid the SW selection API, Implementation SW DeriveSketch API?
The development process encountered efficiency issues. Need help! Thinks!

Re: How to improve the speed of SW selection API

Posted: Thu Feb 17, 2022 12:55 am
by artem

Re: How to improve the speed of SW selection API

Posted: Thu Feb 17, 2022 1:03 am
by ZSJ
Thanks,
Has been used Try to use the API only selection or batch selection,
But it's still slow.
Is there any other way?

Re: How to improve the speed of SW selection API

Posted: Sat Feb 19, 2022 7:23 pm
by josh
turn off graphics update

Re: How to improve the speed of SW selection API

Posted: Sat Feb 19, 2022 8:04 pm
by artem
Are you working in assembly? If so you might want to disable this option as it significantly affects the performance while selecting for large assemblies: https://www.codestack.net/solidworks-ap ... into-view/

Re: How to improve the speed of SW selection API

Posted: Mon Feb 21, 2022 3:10 am
by ZSJ
Thanks,
The speed of selection is greatly improved when the Scroll selected item into view is disabled,
but the speed is still not up to standard when there are too many parts.
Currently disabled:
Scroll selected item
Graphics update
FeatureTree and FeatureTreeWindow
AssemblyRebuild
Is there any other way?

Re: How to improve the speed of SW selection API

Posted: Mon Feb 21, 2022 11:05 am
by Austin Schukar
z1282407454 wrote: Mon Feb 21, 2022 3:10 am Thanks,
The speed of selection is greatly improved when the Scroll selected item into view is disabled,
but the speed is still not up to standard when there are too many parts.
Currently disabled:
Scroll selected item
Graphics update
FeatureTree and FeatureTreeWindow
AssemblyRebuild
Is there any other way?
Have you tried artem's suggestions above? I.e. Bath selection and/or API-only selection

Re: How to improve the speed of SW selection API

Posted: Mon Feb 21, 2022 8:11 pm
by ZSJ
Austin Schukar wrote: Mon Feb 21, 2022 11:05 am Have you tried artem's suggestions above? I.e. Bath selection and/or API-only selection
Yes, used, currently used is AddSelectionListObjects