Hi Guys.
I am new in ARIS scripting.
I am trying to get information of object which is located in the model and model is located in a main group.
Could you please give any example or a advice how to do it?
I tried to make with my owns, but unsuccessful.
I saw the script in standard reports outputobjectinformation(), but I can only select models, if i select groups i did not work.
please help me.
Tricarico Romain on
Hello,
//To find every models in the selected group and sub groups, use this code : var grpMdls = ArisData.getSelectedGroups()[0].ModelList(true); //Then to iterate through every model of the list and find objects involved : var objdefs = new Array(); for(var i = 0; i < grpMdls.length; i++){ objdefs = objdefs.concat(grpMdls[i].ObjDefList()); } //Then you can iterate through every object found to do what you want : for(var i = 0; i < objdefs.length; i++){ var objdef = objdefs[i]; //Do what you need with objdef here. } /*If you want to get the main group : */ var maingroup = ArisData.getActiveDatabase().RootGroup();Best Regards