CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products []
Cesky English Deutsch
 Visitors: 7266 

CAD tip CAD tip # 8632:

Question CAD 
 %  platform  category 
Q - question

Talking iLogic rule to check part material in Inventor (default material).

A - answer With a simple iLogic macro you can check material assignment for each part saved from Inventor.

Creat a a new iLogic rule with the following contents:

materialName = ThisDoc.Document.ComponentDefinition.Material.Name
If materialName = "Generic" Then
 objSPVoice = CreateObject("SAPI.SpVoice")
 objSPVoice.speak ("Your component has no material assigned")
End If

As a trigger for this rule, set e.g. "Before document save". A part with no material assigned will report itself automatically on save, by "telling it" (voice).

The default material for parts, or iLogic macros can be preset in the part template - see I > Save as > Save copy as template.

100% *  CAD 
16.5.2012    6291×  
Comments   Tell a friend
applies to: Inventor 2013 · Inventor 2012 ·

See also:
Tip 11801:What is the difference between ThisDoc.Document and ThisApplication.ActiveDocument in iLogic?
Tip 11732:How to sort BOM or parts list by part number in Inventor? (iLogic)
Tip 11542:How to reset the top browser node name back to the file name?
Tip 11244:Labels with incrementing numbers - assembly with numbered labels for laser cutting.
Tip 11211:Mass change of units in the whole Inventor assembly.

Back   All CAD Tips All CAD tips&tricks

GIS performance analysis in Autodesk Infrastructure Map Server. « | » How to create red-cyan anaglyph from AutoCAD, Inventor or Revit?

Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD:    OS:    Categ: 
Text:  FAQ glossary   

Add .CIT raster format support to AutoCAD and Map and Civil 3D
CITin More info

Please use these tips at your own risk.
CAD Studio (Xanadu) is not responsible for possible problems that may occur as a result of using any of these tips.