Here is another version of the program that allows you to:
- Loading a CSV file containing the list of files to be analyzed, please note that this list must be formatted like the file liste.csv attached with the program.
- Open each file in Solidworks.
- Calculate the outer dimensions of each 3D loaded.
- Save the result in a csv file named résultat.csv and stored in the same directory as the attached executable.
It's best to test a small amount of 3D file copy to get started.
I didn't create the function to save the result in the 3D file settings because as an external person I don't think I have to intervene on them in edit mode.
If you have programming knowledge, I could provide you with the source code of the attached program to adapt to your needs.
Following an improvement request and a few exchanges with froussel, I am making available a new version of the "boundingbox" utility. This new version makes it possible to record the dimensions of the dimensions as well as the mass for each configuration of the Solidworks files.
The new version should make life easier for those who have to size packaging boxes / cartons / case for their parts / assemblies
Attention for EPDM users : the files must exist locally on the computer that launches the program and the version of the local files must be the correct one. if the local file does not exist, the program returns an error message but if the version is "bad" it does the calculation with the version of the local view (but it also allows you to make a comparison between 2 versions if you run the program 2 x on 2 different versions)
I'm sorry to dig up a topic that is 3 years old but I'm having a problem..
I've tried to run your programs one by one but nothing works. In the result file I get opposite each box: non-existent files
I checked the path well, try in a folder on the desktop, with different names (I had a comma in each part name so Excel didn't understand and put question marks instead..), using your "list" file to create my part list, ..
I also thought, I'm on SW20 SP04, does your program work on the new versions?
Thank you so much if you reply again after all this time.
The "Files non-existent" error indicates that the files listed in the liste.csv file are not found or do not exist, how is your liste.csv file written? Can you post it?
Here's what I come across as a file name when I open the list file in a text editor:
We should try with simpler filenames to see if it comes from the SW version (which I doubt) or the filename (a bit complicated). For the essay, it is preferable to avoid names with accents or particular signs.
So yes I thought about it but the problem comes from the fact that: it's the customer who names his parts this way and in a typical assembly there are 700 of them, so too complicated to rename everything unfortunately...
(I did a test out of conscience, with classic "MMPPLATFORM562T1" names, it doesn't work either...)
The error found is in the reading of the file path so before the intervention in Solidworks, which surprises me a little ... Is it possible to take screenshots of the program as I use it and send me the résultat.csv file that results from the test?
Is it possible to try putting the file extensions in the liste.csv file such as "C:\Users\AA\Desktop\TRIALS\MMPPLATFORM562T1.sldprt" otherwise the file is effectively non-existent (even if the extensions are not displayed in Windows, they still exist).
So, I did a test by putting .sldprt, it gives me the lengths well but I have more lines telling me "non-existent file", I guess it's for another function of the program?
So I tried with the original names containing commas and unfortunately it doesn't work.. When opening the result document, the comma of each line appears like this: "ï¿1/2"
Thank you for your help! If you have an idea I'm always interested. (mass renaming or other ..)