how to add onclick event on object A by another object B?
Answered
I want to write some Onclick event on object A by another object B.
The questions I face Is that I want to generate some rectangles by a button, then I want to apply Onclick function on those rectangles. So when I click the rectangles it will rotate 90゚.
I have done the previous Step to generate the rectangle by the bottom. But since the rectangle is new object I can't write down the onclick function before it's generate.
So I'm finding some Way to edit the onclick function on rectangles by other object, I have found some JS function like ObjectOnclickListener but I don't really know how to use it as well.
Is it possible to edit by js?
sorry that my English is poor, and thanks for help.
A demo for reference.
Open the attached ggb file and click on the polygon to see the result.
随时中文交流。
Please post your file
A demo for reference.
Open the attached ggb file and click on the polygon to see the result.
随时中文交流。
Comments have been locked on this page!