13 Replies Latest reply on Jul 14, 2016 2:14 PM by Steve Calvert

    Sub Assembly loads different in top assembly if not opened before the top assembly

    Mark Nohr

      The strange part is that the sub assembly in mangled with elements from a different sub assembly.

      I can say I noticed this after a crash but I have seen this phenomena before on a different design with different sub assemblies.

      The sub assembly being mangled is a relatively large assembly (circuit board).

       

      I'm wondering where to look for problems in the top assembly.

        • Re: Sub Assembly loads different in top assembly if not opened before the top assembly
          Glenn Schroeder

          My best guess is some file reference problems, especially if some models share the same name.

            • Re: Sub Assembly loads different in top assembly if not opened before the top assembly
              Mark Nohr

              Yes the mangling seems to be related to connectors on the circuit boards. there are 3 circuit board sub assemblies in the top level assembly all of which have a J4.sldasm. However each of the circuit board sub assemblies is stored in a different directory and they each have their own J4.sldasm. 

               

              Another thing of note is that the J4.sldasm was created by solidworks when importing a step file.

               

              Also I edited the J4.sldasm associated with the circuit board that is getting mangled to add features for mating.

               

              When I look at the component properties of the J4.sldasm when the circuit board is in the mangled state the Model Document Path correctly points to the correct directory even though the J4 representation on the screen is in the wrong place and the shape is the shape of the J4 from the other circuit board sub assembly.

              Also When the top assembly is in the mangled state, the "What's Wrong" window pops up and says is has rebuild errors.

               

              Again if I open the sub assembly that is getting mangled 1st and then open the top assembly, there are no errors and no mangled models.

               

              Clearly there is a model reference corruption/problem but how do I hunt it down?

            • Re: Sub Assembly loads different in top assembly if not opened before the top assembly
              Mark Nohr

              Understanding: it does seem that the 1st occurrence of a part or sub assembly that is encountered when opening a top level assembly is used throughout all of the assemblies contained within the top level assembly. So if you have multiple sub assemblies with parts or assemblies within them that have identical names but they are different, you will get mangling of every sub assembly after the 1st one opened.

               

              Workaround for this situation:

              This is a way I got around the mangling but in no way do I consider this a solution.

              I carefully ordered the sub assemblies in the top level assembly so that the sub assembly I thought is most likely to change is opened 1st. Then I went through each sub assembly and renamed or hid duplicate named sub-sub assemblies and parts. If/when those sub assemblies change, I'm stuck going back and doing this work again.

               

              If there is a way to force Solidworks to

              recognize hierarchy,

              or use unique identifiers for each sub assembly,

              or rename parts within assemblies in a batch mode,

              or ...

              Please let me know

                • Re: Sub Assembly loads different in top assembly if not opened before the top assembly
                  Glenn Schroeder

                  Mark Nohr wrote:

                   

                   

                  or rename parts within assemblies in a batch mode,

                   

                  You can do that with Pack and Go before inserting the sub-assembly.  Pack and Go gives you the option of adding a prefix or suffix to each file name.

                  • Re: Sub Assembly loads different in top assembly if not opened before the top assembly
                    Anna Wood

                    Pack and Go the assembly and add a pre-fix to the files.

                     

                    Or take the top level circuit board assembly and Save As a sldprt file to combine into a single file.  If all your are doing is packaging around the circuit board, no reason to have to have more then one file in your assembly model.  We do this often for these types of items, lessen complexity with the feature tree in assemblies.

                    • Re: Sub Assembly loads different in top assembly if not opened before the top assembly
                      Steve Calvert

                      I'm confused reading through all this.  Solidworks does things in an order when opening components in an assembly.

                       

                      Here's what's in the Knowledge Base:

                       

                      Question:

                       

                      What is the order used by SolidWorks to search for referenced documents?

                       

                      Answer:

                       

                      1. RAM. If a file with the correct name is already in memory, it will use that file.
                      2. The paths specified in the Folders list on the File locations tab (Tools> Options> System Options> File locations).
                      3. The last path specified to open a document.  When opening a parent document (e.g. an assembly), SolidWorks will search in the same directory for the referenced files.
                      4. The last path used by the system to open a document.  This will apply if the system opened a referenced document last.
                      5. The path where the referenced document was located when the parent document was last saved. This is the path stored in the parent document except that the drive path (C:\, D:\) is considered to be the current drive.
                      6. The path where the referenced document was located when the parent document was last saved with the original disk drive designation. The absolute path name stored with the parent document.
                      7. If the referenced document still cannot be found, SolidWorks will ask to browse for the file.

                       

                      Note that all updated reference paths in the parent document are saved when you save the parent

                       

                      You can see a detailed exaplanation about this, in the SolidWorks help under the topic 'Search Routine for Referenced Documents'

                       

                       

                      If you have files of the same name in different locations across several locations, that would be considered a no-no.  If you have files that are different but have the same file name, then that's bad, too.

                       

                      Steve C