Kombinovaný pohľad Plochý pohľad Stromový pohľad
Témy [ Predchádzajúci | Ďalej ]
toggle
AfterCreateModelingNode
community documentation adoscript trigger
Odpoveď
11.4.2014 12:07
I would like to know, how exactly the "origin" parameter works in the "AfterCreateModelingNode" event.

I would like to create a condition, where a window only pops up when the origin of a created instance is 0.

RE: AfterCreateModelingNode
Odpoveď
11.4.2014 12:08 ako reakcia na Anonym.
The origin parameter is set as an integer parameter directly in the event and can be used to implement the scenario you describe. Please find a little code snipplet attached, the INFOBOX statement needs to be replaced with your code respectively
As for any other parameter available in an event, please consider that you need to create a local/global variable if you want to have access to the parameter in an externally implemented AdoScript file.

 1ON_EVENT "AfterCreateModelingNode" {
 2    IF (origin = 0) {
 3      CC "AdoScript" INFOBOX "DEMO: The object has been created manually"
 4    }
 5
 6    IF (origin = 1) {
 7      CC "AdoScript" INFOBOX "DEMO: The object has been pasted"
 8    }
 9}