CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz]
CZ | EN | DE
Login or
registration
  Visitors: 4578
Plex.Earth connects AutoCAD and Google Earth

CAD tip CAD tip # 12508:

   
Question CAD 
 %  platform  category 
Q - question

How to assign an expression (not value) to a user parameter with iLogic?

A - answer How can I use an iLogic code (rule) to assign (fill) a reference of another parameter or even a full expression to a given user parameter in an IPT model (part)?

You can use the property .Expression of the object Parameter.

See an example:

Dim part As PartDocument = ThisDoc.Document
'MyParam and MyValue are names of existing parameters
part.ComponentDefinition.Parameters.UserParameters("MyParam").Expression = "floor(MyValue / 1 mm) * 1 mm"
Inventor
100% *  CAD 
13.2.2020    3360×  
Prices - CAD eShop:
applies to: Inventor ·

See also:
Tip 13197:How to transfer a model or sketch parameter to iProperties?
Tip 12462:Mass- (table-) rename parameters in Inventor.
Tip 12392:Export unfolds of sheetmetal parts to DXF - parameters for iLogic and VBA
Tip 12046:Random shape and appearance of an Inventor part or assembly.
Tip 12024:How to create a custom iProperty or Parameter with iLogic?


Back   All CAD Tips



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   



Featuring:
DwgTextTranslator translates a series of drawings from one language to another using MS Access.
Download a fully functional trial version.


Please use these tips at your own risk.
Arkance Systems is not responsible for possible problems that may occur as a result of using any of these tips.
TOPlist