General InformationThis opening ID is invoked when you synchronize your cable routes information with your cables in the Cable Management command. For more information, see Electrical 3D Design User's Guide: Synchronizing Cables with Cable Routes.
Input ObjectsInput objects must be of the following types:
Context Object Parameters
Sample
let ListInputRoutable(LIST) let ListAttr(LIST) let ListListAttrValues(LIST) let ListAttrValues(LIST) let ListInputRoutable2(LIST) let ListAttr2(LIST) let ListListAttrValues2(LIST) let ListAttrValues2(LIST) let currentObj (Feature) let route (ElecRoute) let cable (Elec3DCable_Inst) let cableRef(Elec3DCable) let index (INTEGER) let index2 (INTEGER) let strAttr(STRING) let routeLen(LENGTH) let condMass(MASS) set ListInputRoutable = Parameters.GetAttributeObject("ListRoutes") ListAttr = Parameters.GetAttributeObject("ListAttributesOfRoutes") ListListAttrValues = Parameters.GetAttributeObject("ListAttributeValuesForRoutes") set ListInputRoutable2 = Parameters.GetAttributeObject("ListCables") ListAttr2 = Parameters.GetAttributeObject("ListAttributesOfCables") ListListAttrValues2 = Parameters.GetAttributeObject("ListAttributeValuesForCables") if (NULL <> ListInputRoutable) { index = 1 for index while index <= ListInputRoutable.Size() { set currentObj = ListInputRoutable.GetItem(index) set route = currentObj ListAttrValues.RemoveAll() index2 = 1 for index2 while index2 <= ListAttr.Size() { set strAttr = ListAttr.GetItem(index2) if(strAttr == "Name") { if(NULL<>route) ListAttrValues.Append(route.Name) else ListAttrValues.Append("NotFound") } else if(strAttr == "Comment") { if(NULL<>route) ListAttrValues.Append("OK") else ListAttrValues.Append("NotFound") } else if(strAttr == "Length") { routeLen = 0mm ListAttrValues.Append(routeLen) } else ListAttrValues.Append("NA") } ListListAttrValues.Append(ListAttrValues) } } if (NULL <> ListInputRoutable2) { index = 1 for index while index <= ListInputRoutable2.Size() { set currentObj = ListInputRoutable2.GetItem(index) set cable = currentObj set cableRef = cable.Reference ListAttrValues2.RemoveAll() index2 = 1 for index2 while index2 <= ListAttr2.Size() { set strAttr = ListAttr2.GetItem(index2) if(strAttr == "Name") { if(NULL<>cable) { ListAttrValues2.Append(cable.Name) } else ListAttrValues2.Append("NotFound") } else if(strAttr == "Sub Type") { ListAttrValues2.Append("NotFound") } else if(strAttr == "Length") { routeLen = cableRef.V_Elec_Length ListAttrValues2.Append(routeLen) } else ListAttrValues2.Append("NA") } ListListAttrValues2.Append(ListAttrValues2) } } if(ListListAttrValues.Size() <> ListInputRoutable.Size()) { Parameters.SetAttributeInteger("severity", 2) Parameters.SetAttributeString("Message", "Computation Failed!") } else if(ListListAttrValues2.Size() <> ListInputRoutable2.Size()) { Parameters.SetAttributeInteger("severity", 2) Parameters.SetAttributeString("Message", "Computation Failed!") } else { Parameters.SetAttributeInteger("severity", 0) Parameters.SetAttributeObject("ListAttributeValuesForRoutes", ListListAttrValues) Parameters.SetAttributeObject("ListAttributeValuesForCables", ListListAttrValues2) } |