Attempting to add an object with an attached process flow, to a user library which already contains an auto install component, throws the following exception :
exception: FlexScript exception: invalid index at MAIN:/project/exec/globals/nodefunctions/addtouserlibrary/Object attached to Process Flow/onPostAdd
The object is added to the library, but the process flow is not.
Reproduction:
- open the attached model
- add GlobalTable1 to a new user library as an auto-install component
- add ObjectWithProcessFlow to the same user library
Fix :
MAIN:/project/exec/globals/nodefunctions/addtouserlibrary/Object attached to Process Flow/onPostAdd
Line 52 :
treenode tempObj = temp.subnodes[j]
Should be :
treenode tempObj = temp.subnodes[k]
Thanks to @Pierre-Yves for finding, debugging and reporting this issue (and fix) to us!