Relating x,y to left,top

S

Steve

Does anyone know how I can relate the x,y values from the mousemove event to
the .top and .left values of a rectangle object moved with the cursor on a
chart.

I am trying to move a rectangle around a bar chart without having it
selected so that I can continue to use the mousemove event to relate the
cursor position to what is in the chart at that point -so that I move it
around the chart. If I select the rectangle so that the cursor drags it then
the mousemove event is disabled - I presume because the mouse is not over
the chart but is over the rectangle.

I hope all that makes sense and someone can help.

Thanks in anticipation

Steve
 
J

Jon Peltier

Steve -

Those x,y values are in pixels. The rectangle's .top and .left are in
points. Multiply the x,y by 0.75 to get points.

- Jon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top