Error when using replace/replace all in an assembly

Error when using replace/replace all in an assembly

Christian3.14
Advocate Advocate
3,022 Views
12 Replies
Message 1 of 13

Error when using replace/replace all in an assembly

Christian3.14
Advocate
Advocate

I recently changed the names of hardware such as screws and washers that are used in a bunch of assemblies. All of the hardware files are kept in a local folder.  I go into the assembly and as expected it can't locate the files since the names changed. Lets say the files it can't locate are Screw A, Screw B, Screw C, Washer A. To resolve the link, I use the replace all command on Screw A and find the updated file name. For Screw A, it replaces all the iterations in the assembly it with no issues, not even a broken constraint. When I go to replace all other hardware in the assembly after that (Screw B, Screw C, Washer A), it replaces all iterations in the assembly with seemingly no issues. Everything in the model looks normal and all the constraints are there. However, in the model browser next to each of those resolved parts (Screw B, Screw C, Washer A) is the blue i error symbol (the blue i symbol is not present for the first piece, Screw A, and all other iterations of Screw A). I've tried everything to get rid of that error, but the only solution I found is to replace the components with the errors (Screw B, Screw C, Washer A) again, choose a random piece in the same family (Screw Y, Screw Z, Washer Y), accept the replacement, replace those pieces (Screw Y, Screw Z, Washer Y), choose the correct pieces (Screw B, Screw C, Washer A) and accept the replacement. After that, all the errors are gone. I should also note that whatever piece I replace first won't have any issues. I could have replaced Screw B first and then Screw A, Screw C, and Washer A would have the errors. Can anyone give insight on what's going on here? Am I not doing something correctly? I can provide a screencast if that helps out.

0 Likes
3,023 Views
12 Replies
Replies (12)
Message 2 of 13

swalton
Mentor
Mentor

I think your workflow is something like this:

  1. Build an assembly (bob.iam) and add fasteners
  2. Decide that the file names of the fasteners are wrong
  3. Change the file names with Windows Explorer
  4. Open bob.iam and find broken links to all the fasteners
  5. Use replace/replace all to change from the old fasteners to the new ones.

After Step 4, Inventor should have presented you with a find window where you could navigate to the missing file(s).  Instead of selecting the missing file, select the renamed file.  Inventor will use the selected file for every instance of the missing file.  No need to use the replace/replace all commands.

 

Did you see the find window?

 

In the future, consider using the Design Assistant tool that is installed with Inventor.  That tool will let you open a top-level document, like an assembly or drawing, and rename all the member files, like fasteners.  When the member files are renamed, the Design Assistant will fix all the references in the top-level document. 

 

Steve Walton
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Inventor 2025
Vault Professional 2025
0 Likes
Message 3 of 13

Christian3.14
Advocate
Advocate

Yes, that is my workflow. Now that you say it, for some reason, that find window doesn't come up. But also, that find window wouldn't be too helpful. Most of the hardware are made from iParts, so when I replace them, I can choose the parent iPart and then select from the table using their parameters and iProperties rather than having to remember or find the name that I changed it to. If I were to choose the parent iPart through the find window, it wouldn't like that. As for design assistant, I had to rename a few hundred files, some of them haven't been used in an assembly yet so they wouldn't show up in a design assistant assembly. And since most of them were made using iParts, I had to update the member name in the iPart as well as the filename in windows explorer.

0 Likes
Message 4 of 13

swalton
Mentor
Mentor

I'm not sure why you are getting the blue icon.  I wonder if using the replace/replace all command on components that are not resolved is an unsupported workflow.  It may be that Inventor does not update the resolved status correctly.

 

Have you tried the rebuild-all command?

 

Another way to avoid the issue would be to make new iPart factories and member files when you need to rename old fasteners.  That way you can open the parent assemblies with resolved parts, and then replace them with the new files without breaking any links.

 

 

Steve Walton
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Inventor 2025
Vault Professional 2025
0 Likes
Message 5 of 13

johnsonshiue
Community Manager
Community Manager

Hi Christian,

 

The typical error I am seeing is usually related to geometry reference (adaptive, constraint, or joint). There could be bugs or the errors are legitimate due to missing geometry. Please share the files here or with me directly johnson.shiue@autodesk.com.

Many thanks!



Johnson Shiue (johnson.shiue@autodesk.com)
Software Test Engineer
0 Likes
Message 6 of 13

Cris-Ideas
Advisor
Advisor

@johnsonshiue 

Hi Johnson,

He is not playing with the geometry but with file naming. So there are no changes in geometry.

Also he says that all works fine with first replaced item and have problems only for the rest.

 

@Christian3.14 

Try the other way around.

1) you have your assembly, you do no like file naming of the parts

2)

a) if there are only a few of the parts you need to change

use "Save and replace" from assemble ribon and rename the file as required. After that use "replace all" for all other instances of a given part.

b) if there is a lot of parts you need to rename

copy all of those parts (copy do not delete originals) to another folder within your project structure. Rename files in this folder

Go to your assembly (have no missing references, as you did not delete the files). Use "replace all" for all of the components you need to replace.

 

I never have any problems following this procedures.

 

Cris.

Cris,
https://simply.engineering
Message 7 of 13

Christian3.14
Advocate
Advocate

 I have tried rebuild all but that doesn't work. I also can't make new iPart and member files. All these files are in a version control system (not vault) so I have to directly make name changes to the existing files through version control 😕.  @Cris-Ideas 

0 Likes
Message 8 of 13

Christian3.14
Advocate
Advocate

No geometry is missing. It's the same file, just a different file name. Missing geometry also doesn't explain why I can do a double replace to fix the issue. 

0 Likes
Message 9 of 13

johnsonshiue
Community Manager
Community Manager

Hi Christian,

 

Does it happen to a specific assembly or it is a general issue?

Many thanks!



Johnson Shiue (johnson.shiue@autodesk.com)
Software Test Engineer
0 Likes
Message 10 of 13

Christian3.14
Advocate
Advocate
It’s a general issue. It happens with every assembly.
0 Likes
Message 11 of 13

Cris-Ideas
Advisor
Advisor

Can you make a simple test and come back with the result:

 

1) open your assembly (original with no missing references)

2) select one of the parts you need to replace

3) use "save and replace" (give the new part any name you require)

4) use component -> replace all for all reining instances of the component you are replacing.

 

little video reference:

 

Cris.

Cris,
https://simply.engineering
Message 12 of 13

johnsonshiue
Community Manager
Community Manager

Hi Christian,

 

Cris recorded a very informative video. You may want to take a look. But, I think something is missing here. It is either a bug or something else is blocking it from working correctly. If possible, please share an example here. I would like to understand the behavior better.

Regardless, renaming files is better done via Design Assistant or Vault. Changing in File Explorer can lead to confusion or incomplete swap. Also, you want to avoid having files with same name in different folders (accessible by the Project). Inventor is a file-based CAD system. When you have same-named files in the project folder, the resolving behavior can be unpredictable.

Many thanks!

 



Johnson Shiue (johnson.shiue@autodesk.com)
Software Test Engineer
0 Likes
Message 13 of 13

Cris-Ideas
Advisor
Advisor

As Johnson said


@johnsonshiue wrote:
.... Inventor is a file-based CAD system. When you have same-named files in the project folder, the resolving behavior can be unpredictable.

 


Actually if you have files with the same name in project folders inventor asks you which one to use.

 

As for my self I use this this as a advantage in some cases, especial when I need to change language of the project or I need to switch the project to use identical parts from different supplier.

Than having identically structured libraries with identical fine names I am able to simply substitute English library to Polish by re-routing library paths in the project.

 

Cris

Cris,
https://simply.engineering
0 Likes