0
$\begingroup$

I have a main file. I use a split feature to break it into two parts and save them as separate files.

My goal is to change some dimensions in main file and the children files (the split files) getting updated automatically without opening these.

I have tried the following:

  1. Solidworks Task Scheduler. (Update files, Update associated files) but didn't work.
  2. Macros.

What did I do in macro?

I noticed that if I edited the split command and just clicked on the green tick without making any changes, then Solidworks updated the split files automatically. So I recorded a macro for this, cleaned it up, changed to get intellisense (that SldWorks.SldWorks magic) but it didn't update the split files when I executed it.

I am attaching the sldprt files and the macro. PS: I am also open to altogether new approach to achieve my objective.

https://drive.google.com/drive/folders/1DxmbctkrmwwZngUBBpwivN0MCoTUBIzi?usp=sharing

$\endgroup$
2
  • $\begingroup$ ... where are you attaching the files? $\endgroup$ Commented Oct 16, 2021 at 0:07
  • $\begingroup$ I have edited the question. forgot to attach the files earlier. $\endgroup$ Commented Oct 16, 2021 at 7:50

1 Answer 1

1
$\begingroup$

I think you may be misunderstanding what causes the child parts to become "updated".

There is no need to edit the split command.

In order for the changes to propagate to the child, the following needs to happen:

  1. The parent part must be open in SW
  2. The child part must be rebuilt

So, if you have all three parts open (one parent and three children), then any changes that you make to the parent part (before the split feature in the history tree) will immediately be reflected in the child part when you switch to it.

If you have the child parts closed, you edit and then save the parent part, and then open the child parts to 'see if they have been updated', then they will appear with the old geometry. BUT they will also appear with a warning question mark showing that the reference is out of context.

Out of context warning

The child can't pull any geometry from the parent part until it is loaded into RAM.

The quickest way to open the parent part up is right clicking and using "edit in context". Once the parent part is updated, you can switch to the child, rebuild it, and see your changes.

edit in context

So - to the solution: change your settings such that SW automatically loads any changed external references into RAM. There is a checkbox that sets them to load into memory only, and not clog up your "window" list.

Load to memory

Once you have changed this setting, you will find that when you open up the child part, the reference is now in context, and the changes that you made to the parent are visible as you wanted.

The only reason to not have this enabled (and to therefore manually load references as needed) would be if you are working on very large assemblies, and need to speed up opening times.

$\endgroup$
3
  • $\begingroup$ I have made these changes and tested it out. I am using Solidworks task scheduler to update the files. Everything is working fine now. Thank you so much. $\endgroup$ Commented Oct 16, 2021 at 7:51
  • $\begingroup$ I'm glad it's working, but task scheduler shouldn't be required? I didn't need it in my testing anyway. $\endgroup$ Commented Oct 16, 2021 at 8:28
  • $\begingroup$ You are right Jonathan. But I want to do batch processing of about 3000 files. $\endgroup$ Commented Oct 19, 2021 at 16:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.