@Anonymous wrote:
I want to use iLogic to create User Parameters with Multi-Value lists filled with info from an excel spreadsheet. What is the code to create a new User Parameter? I can't seem to find it in the help wiki.
Thanks!
Format:HTML Format
Version:1.0
StartHTML: 165
EndHTML: 7452
StartFragment: 314
EndFragment: 7420
StartSelection: 314
EndSelection: 314
oMyParameter=ThisApplication.ActiveDocument.ComponentDefinition.Parameters.UserParameters
'Setting an userParameter as inches
oParameter=oMyParameter.AddByExpression("Length_inch", "3", UnitsTypeEnum.kInchLengthUnits)
oParameter=oMyParameter.AddByExpression("Width_inch", "3", "in")
'Setting an userParameter as Millimeteres
oParameter=oMyParameter.AddByExpression("Length_mm", "3", UnitsTypeEnum.kMillimeterLengthUnits)
oParameter=oMyParameter.AddByExpression("Width_mm", "3", "mm")
'Setting an userParameter as text parameter
oParameter=oMyParameter.AddByValue("color", "bule", UnitsTypeEnum.kTextUnits)
oParameter=oMyParameter.AddByValue("color", "red", UnitsTypeEnum.kTextUnits)
oParameter=oMyParameter.AddByValue("color", "yellow", UnitsTypeEnum.kTextUnits)
the above example creates single user parameters
but i dont know wheteher there is a way to create a Multi-value user parameter
Please mark this response as Problem Solved if it answers your question.
----------------------------------------------------------------------------------------------
Ravi Kumar MB,
HP Z220 SFF Workstation
Autodesk Inventor Certified professional 2016
Email: ravikmb5@gmail.com
