Message 1 of 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
i try to create MultiValue Lists that depend on other MultiValue Lists. Long Story short, i have a form where i can change material "Kupfer" and "Aluminium". If i choose "Kupfer" the MultiValue of "rm_rohr_typ" should be "1_XXX, 2_XXX, 3_XXX and 4_XXX". If i choose "Aluminium the MultiValue of "rm_rohr_typ" shouldt be "1_YYY, 2_YYY and 3_YYY".
The rule should check, if the user parameter exists, if yes only the MultiValue should change. If not, the user parameter should create with the MultiValue.
If this works, i can complete the rule with additional IF THEN - For example: IF Kupfer and 1_XXX use blue, IF Kupfer and 2_YYY use green....
Thanks in advance.
Regards Martin
iLogicVb.UpdateWhenDone = True oMyParameter = ThisApplication.ActiveDocument.ComponentDefinition.Parameters.UserParameters Try 'Change value of param Parameter("rm_rohr_material") = "Kupfer" Catch 'Create Param as it doesn't exist oParameter=oMyParameter.AddByValue("rm_rohr_material", "Kupfer", UnitsTypeEnum.kTextUnits) Parameter.Param("rm_rohr_material").Comment = "Rohmaterial Kupfer" MultiValue.SetList("rm_rohr_material", "Kupfer", "Aluminium") End Try MultiValue.SetList("rm_rohr_material", "Kupfer", "Aluminium") If rm_rohr_material = "Kupfer" Then Try 'Change value of param Parameter("rm_rohr_typ") = "1_XXX" Catch 'Create Param as it doesn't exist oParameter=oMyParameter.AddByValue("rm_rohr_typ", "1_XXX", UnitsTypeEnum.kTextUnits) Parameter.Param("rm_rohr_typ").Comment = "Rohrleitungstyp" MultiValue.SetList("rm_rohr_typ", "1_XXX", "2_XXX", "3_XXX", "4_XXX") End Try MultiValue.SetList("rm_rohr_typ", "1_XXX", "2_XXX", "3_XXX", "4_XXX") Else If rm_rohr_material = "Aluminium" Then Try 'Change value of param Parameter("rm_rohr_typ") = "1_YYY" Catch 'Create Param as it doesn't exist oParameter=oMyParameter.AddByValue("rm_rohr_typ", "1_YYY", UnitsTypeEnum.kTextUnits) Parameter.Param("rm_rohr_typ").Comment = "Rohrleitungstyp" MultiValue.SetList("rm_rohr_typ", "1_YYY", "2_YYY", "3_YYY") End Try MultiValue.SetList("rm_rohr_typ", "1_YYY", "2_YYY", "3_YYY") End If
Solved! Go to Solution.