Solidworks without Userinterface

I need to import hundreds no thousands of step file into Solidworks, set a custom coordinate system and export in parasolid format. Programming the process as a macro is no problem, but importing the step files takes a long time.
Therefore I am looking for a way to speed up the process.
I have already tried if the use of the command line arguments brings something, but this is not so. (My hope was that the parameter /b could have a positive effect).
I found another article that mentions that you can start Solidworks without UI.
→ CAD-System API without UI - Software Recommendations Stack Exchange

I would like to try this option and see if it gives a speed advantage. Does anyone know with which commands or parameters you can start Solidworks without UI?

There is a bit of info here of command line arguments.

This can be paired with a script to start Solidworks with the Solidworks application setting visible to false. There are additional things to set that can speed up performance.

The following article outlines a lot of this in detail.

Edit: setting the session “Visible” to false can cause some API functions to no longer work, so consult the help documentation for any API calls you may be using.

1 Like

I wrote the article mentioned above. You make solidworks faster by disabling some of its features like feature tree updating, sketch relations etc. But I don’t think importing STEP files will get notably faster with those items disabled. Please let us/me know if it does, though.

1 Like

Use the macro with 3dInterconnect on. This will definitely improve the speed.

But does that really import the STEP file or does it do a quick read or something? Because the link to the STEP file remains and needs to be broken later on.

I have recently learned that 3D Interconnect really uses a new importer, but the documentation is still very scarce.

I need to import hundreds no thousands of step file into Solidworks,

You mean hundred of thousands?

You’re stuck or at least it seems like it.

SOLIDWORKS API is bound to the SOLIDWORKS application so you get the whole thing with the good, the bad, and the worse. You also have a lot of IO operations to contend against.

Your best bet is to develop a distributed application and divide your files into small batches handled by each instance running your application.

You can probably process all of your files in a couple of days.

Definitely reach out (Amen J. - Vancouver, British Columbia, Canada | Professional Profile | LinkedIn) if you want us to take this on.

I’m not sure how does that work but yes it would be helpful and since @Hansjoerg need to export them to parasolid, break the link would not be required.

If you really just want to get Parasolid, then I imagine it’s faster to do it from the eDrawing command line.

However, I have not tested it.

2 Likes

eDrawings is maybe just as bad as as SOLIDWORKS in terms of performance. It is even worse when it comes to showing the latest actual build of the doc.

here I am back again,

in the meantime I have programmed diligently and my macro for the processing of the data stands so far.

Thanks for all your suggestions and ideas.

@BigCrazyAl: do you have more information about the command line arguments? I read the info on the linked page, but unfortunately also the info from AmenJlili that most of them are useless.

@PeterBrinkhuis I know your very informative page :slight_smile:
I have already played a bit with a few settings, but as you have already guessed correctly, the settings have little influence on the speed of the step import.
I discovered in a sample macro from AmenJlili another method to increase the speed:
CommandInProgress Property (ISldWorks) - 2021 - SOLIDWORKS API Help.
I will test it.

@Gupta: In the Interconnect interface there is a problem when importing step data created with Hicad → SPR 892378 the bug should be fixed in SWX 2023 SP1, currently we are still on SWX 2021 SP5,1 but as soon as we have switched I will test Interconnect.

@AmenJlili: There will be a hell of a lot, I can’t say exactly how many there will be in the end. Unfortunately we have to re-export all the data with the old CAD system first, because the data generated so far is all unusable. The bottleneck is the action in the generate system.

@Deckemaho: The parasolid file is only temporary. I need the file only for the reimport with a special extended additional coordinate system. In the CAD system from which the data comes, the Z-axis is vertical. Without this step, all models in SWX are on the front view.

1 Like