01-10-2015 06:29 AM
hello!
I am actually drawing a drawing a rectangle over xy graph using mouse clicking events and I need coordinates exactly the way it is extracted by cursor.The indicator ''coord2'' & ''cursor 0'' should give me same results.I need output of coord 2 to be like cursor 0.Hope i managed to convey my point.May be i have to manipulate with scale.Check the attachment.
Solved! Go to Solution.
01-10-2015 02:09 PM
Sets,
I attached a VI that will turn your mouse up and down coordinates that are by default in pixels to x-y coordinates. I also noticed that you were only able to make a rectangle when you started in the upper left and ended in the bottom right so I added some logic so you can start and end anywhere and have the rectangle be drawn.
I also noticed that when drawing the rectangle the corners were drawn slightly below and to the left of the cursor, is this the issue you were actually trying to fix? I just looked into that a little bit but couldn't figure out why that was happening.
01-13-2015 10:11 AM
I actually changed and replaced the graph with intensity graph but this time i managed to extract cooridinates wrt to scale in a much easier way.Unfortunately, I am unable to draw rectangle on the position where I click on the graph but unable to locate any square.I am using mouse down event and then holding the button and changing the position to another position on graph and when mouse up event comes my second coordinate is extracted.Kindly check the attach VI