As part of a project, I want to create a 3D configurator in SolidWorks. While rummaging around on the internet I discovered this forum and I hope that some people will be able to help me because unfortunately I am no longer moving forward on this project ... Let me explain my problem:
I want to create custom assemblies a bit like when you go to configure your car at the dealership. In my case, it is a question of creating a configurator on an assembly with 3 key parts: A tap (10 types of taps possible), a basin (6 or 7 types possible), and a last part that I would not specify for confidentiality reasons (10 types of parts).
I created a bunch of configurations on an assembly that currently only includes faucets and basins in order to have a basis to practice creating this configurator. In the idea, I would like my user to select via a drop-down menu his tap, his basin and the last mystery part and that the assembly in the configuration selected by it is displayed.
I started using DriveworksXpress for this project but I'm very limited when it comes to configurator rules... In other words, I know how to create the forms but it is impossible for me to generate an assembly at the end, my rules being totally wrong.
I also saw that it was possible to carry out this project using a VBA macro under SolidWorks, again I don't have any programming skills (I can force myself to learn of course). I think the best solution would be DriveWorks for me, what do you think?
Could you help me by giving me for example a generic rule to indicate in DriveWorks that I would adapt according to the name of my configurations and my parts?
In the case of a VBA macro, have any of you ever faced this kind of problem? Do you have any examples to suggest to me?
Driveworks is indeed a good choice (it's typically made for that)
Without starting with this kind of module, a good old family of parts in excel should be able to give you the result you expect (if for example you insert all your parts in an assembly and you manage the deletion/deletion states by excel).
The interest of excel is also to be able to make links with external excel files (or databases), to be able to add a second sheet to control your sheet containing your family of parts (would allow you to do something more user friendly with drop-down lists for example...).
Excel also allows you to do calculations / verification to prohibit configurations, set rules...
At the limit Excel is able to generate your 10*7*10=700 different configurations if you really need them (it may grind a little though...).
Try to contact http://www.lynkoa.com/membres/thomasguillard
Here is his profile
IFMA mechanical engineering training. I have been using solidworks on my own since I was 14 years old and I learned Catia at school. Now an engineer at DriveWorks, a SolidWorks Gold Partner that allows you to automate your SolidWorks designs and provides you with a 3d configurator and sales. http://www.driveworks.co.uk/
I'm going to contact the person for some explanations about DriveWorks!
In the same way, I would also try it with Excel. I actually want to control the state of deletion of the parts according to the desired configurations! I'll keep you posted if I ever get there!
DriveWorksXpress is free but limited, DriveWorks is paid but much more advanced.
If you have a good knowledge of Excel you can create the configurator of your dreams without any problem. The question is do you have a good knowledge of Excel?
Under DriveworksXpress, you need to select one of your components and then go to Drawing & Configurations, check the box: 'Yes, let me create a rule to change the configuration'. Then in the rule editor you create a rule on the config. If, for example, in your form you have a multiple choice TypeofTap with Tap A, Tap B, Tap C. your rule can be for example:
Thank you very much for your answers! Regarding the c.fer rule I tried with 2 configurations and it works! So I'm going to continue on DriveWorks but I haven't said my last word lol. As you talked about managing my configurator via Excel, I'd like to do it too, just to master both possibilities.
Unfortunately I don't master Excel perfectly... Do you have any examples of files that you have already made? Or give me an example to manage a configuration a bit like c.fer did but via Excel?
Should I create the Excel file and then link it to my assembly or create an automatic part family table and then manage it? And what are the steps to follow to do so?
If you had a small example of an Excel file with two or three pieces forming an assembly, it would be perfect...
Thank you again for your answers! This forum is really great
There are answers for DriveWorks and for Excel, so here is one in VBA macro to complete.
To use the join macro, you must first open 1 assembly in Solidworks consisting of 1 to 3 parts with different configurations. When the macro is launched, it notes the names of the rooms and their configurations, when the form is displayed, you have to choose the configuration for each room and then click on the "configure" button.
This macro is only an example and, as such, does not contain all the necessary checks and error handling.
This macro is written in SW 2017, so make sure to change the references in the macro editor if necessary.
Many thanks to OBI, d.roger, thomas, cfer and gt22 for your answers. I have quite a few leads that I will exploit thanks to you. I'm going to work on it properly this week. I will get back to you by next Friday with I hope good news. In any case, I'm happy to see a community like this! Mutual aid is the key to any project!
D.Roger, I just tried your macro. It opens without any problem however I have a small question. In fact, my faucets have no geometric connections to each other. They are all different parts with totally different geometries. The same goes for the basins and for the room that I won't specify.
Basically, I created configurations in my assembly with faucet 1 and sink 1, faucet 2 and sink 1 ect ect ...
How can I adapt your macro to my needs, for example?
The configs are all present in my tree, I just want to manage the deletion state of my parts.
Basically, the idea is from your macro, I choose my faucet via a drop-down menu with all my faucet parts, I then choose my basin in the same way and finally my 3rd piece and presto, the assembly is generated.
Indeed, seen like this, the macro takes another turn.
Do your types of parts have a common point by family, let me explain, do the names of your taps all start with "R", the names of your basins with "V" and the name of your mystery pieces with "M" (or other of course), this would allow when analyzing the threaded elements of the assembly to classify each piece in the right category. From there, you just have to hide or show the elements of the tree according to the user's choice, there are functions in the APIs that allow you to do this.
Yes, my taps all start with R, the Basins also start with V, the mystery room follows the same logic. In my assembly tree, I have stored the faucets in a folder called faucet, the same for the basins.
What are these functions you are talking about? Do you have an example of a macro that handles this? Should I leave the folder for each family in my assembly tree?
Thank you again for your help
Kind regards
PS: If you wish, I can transfer the assembly to you.
Ok, I'd like you to transfer the assembly to me (even with empty parts for the sake of confidentiality). Having availability at the moment, I'm going to give you an example of a macro tomorrow or Monday at the latest.
If for privacy reasons you are afraid to transfer the files you can send them in private message to d.roger. I have also already done this via Wetransfer, just send the link in a private message by clicking on his nickname.
Another great job by Mr Roger the demigod of macro ;-)
On the macro managing the configurations, it must surely be possible to modify it so that it becomes "generic" by doing the same thing but for an assembly containing x parts (or parts and subassembly) right?
So modified in this way it could be used by many more people (I would love to have assemblies limited to 3 parts ...). It would then become a very user-friendly assembly configurator (no need to click on each part in the tree to be able to change (or not) the configuration)
Being taken by feelings ;-) , I'll look into the subject and see what I can propose, the most complicated may be to put a little more in the vba (sniff), I who follow more comfortable with the C#.