& Construction

Integrated BIM tools, including Revit, AutoCAD, and Civil 3D
& Manufacturing

Professional CAD/CAM tools built on Inventor and AutoCAD
Integrated BIM tools, including Revit, AutoCAD, and Civil 3D
Professional CAD/CAM tools built on Inventor and AutoCAD
I'd like to be able to indicate what LOD should be used when I place a component using iLogic. I have no troubles placing the component using iLogic, but I haven't figured out how to indicate the LOD in the placing process. I know this should be possible because when placing the component using the "Place Component" button one can use the "Options..." button to indicate what LOD should be used. How do I replicate this with iLogic? Is there an option that can be set or should the file name be altered in some way?
Hello,
When specifying the file path, add "<LODName>" at the end of the path. And use it as input when placing the component.
Dim filePath As String = /path/to/file.iam<LODName>
Alternatively, you can place the component in master LOD and change to the desired LOD. It is less optimal as this will load the whole assembly in the memory while selecting LOD first will load only the active component.
Occurrence.SetLevelOfDetailRepresentation(LODName)
What you've written makes sense, but still doesn't seem to work for me and throws an error. The LOD I'm trying to initialize is called "Standard" but when I attempt to execute the code using a file path of the form "path\myComponent.iam<Standard>" it states that an illegal character (the < and >) is being used. Have I set this up incorrectly?
Hi @duke .
Here is a link to the online help page or adding a component into an assembly, while specifying 'options'.
ComponentOccurrences.AddWithOptions Method
Basically you would have to create a new NameValueMap object ahead of that Add line, then set the needed name/value pairs within it, then supply that NameValueMap to the end of the Add line as specified in this link. Have you ever created or worked with a NameValueMap before?
If this solved your problem, or answered your question, please click ACCEPT SOLUTION.
Or, if this helped you, please click (LIKE or KUDOS) 👍.
If you have time, please... Vote For My IDEAS 💡or you can Explore My CONTRIBUTIONS
Inventor 2021 Help | Inventor Forum | Inventor Customization Forum | Inventor Ideas Forum
Wesley Crihfield
(Not an Autodesk Employee)
How to buy
Privacy | Do not sell or share my personal information | Cookie preferences | Report noncompliance | Terms of use | Legal | © 2025 Autodesk Inc. All rights reserved
Type a product name