I have a dialog based MFC application that reads the coordinates of height and radius from a text file and displays it as a plot of points on a picture control window. Now, after the points have been plotted I need to be able to drag and drop a point to any particular location in the window in order for me to have the points coordinates changed to its new location. All this should be done by dragging and dropping it with my right click button. I do understand that the event that I should be using would be OnRButtonDown() and OnRButtonUp(), but I am unable to understand as how to include the drag and drop feature in my application. For your information, I have done the plotting of points, I just need to understand the implementation of dragging and dropping feature.
Thanks in advance.
Several things for drag & drop:
You might also need to use SetCapture/ReleaseCapture in your OnRButtonDown()/OnRButtonUp() for the cases that you dragging and moving the mouse out of your dialog window.