Problem with event.getX or Y
Posted: Wed Nov 17, 2010 4:26 pm
I try to get the location of a field onSelection in the client Design Mode. I know that the location is x:0 and y:0 because I place it myself.
In the method onSelection(event):
If I run the debugger the event.data returns x and y as 0, but the application output returns random values as "75 / 199" or "39 / 92".
I also tried with event.data[0].getX() but it returns with an error.
what can I do to get the x and y from the data?
In the method onSelection(event):
- Code: Select all
var x = event.getX()
var y = event.getY()
application.output(x + ' / '+ y)
If I run the debugger the event.data returns x and y as 0, but the application output returns random values as "75 / 199" or "39 / 92".
I also tried with event.data[0].getX() but it returns with an error.
what can I do to get the x and y from the data?