Thanks, I have found it...
I am now calculating the position of the mouse in the picturebox, but have
some slight problems.
PopupMenu.MenuItems.Clear();
MenuItem XPos = new MenuItem();
XPos.Text = "X : " + (MousePosition.X - GraphDisplay.Location.X);
MenuItem YPos = new MenuItem();
YPos.Text = "Y : " + (MousePosition.Y - GraphDisplay.Location.Y);
PopupMenu.MenuItems.Add(XPos);
PopupMenu.MenuItems.Add(YPos);
(My picturebox is called GraphDisplay).
I am trying to get the coordinates with reference to top left of picture
box, The X Position is perfect, the top position (Y) looks like it is taking
into account the title area (where the start button etc. is).
Is the title bar height consistent? How high is it? (Looking for "Start menu
height" on google doesn't show anything.)
--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com ~~
http://www.FOCUSPortals.com - Local franchises available
"Paul G. Tobey [eMVP]" <p space tobey no spam AT no instrument no spam DOT
[quoted text, click to view] com> wrote in message news:O37ZgECZIHA.4880@TK2MSFTNGP03.phx.gbl...
> Look up "context menu tap and hold" in the archives of this group:
>
>
http://groups.google.com/group/microsoft.public.dotnet.framework.compactframework/topics?hl=en&lr=lang_en&ie=UTF-8&oe=UTF-8
>
> Paul T.
>
> "David" <david.colliver.NEWS@revilloc.REMOVETHIS.com> wrote in message
> news:OVvNj8BZIHA.4208@TK2MSFTNGP04.phx.gbl...
>> Thank you, I was considering this route already, but what I would have
>> preferred is a 'context sensitive' type of pop-up. Basically, hold the
>> pointer down, get the dots rotating around the pointer and pop-up my
>> information.
>>
>> Also on this pop-up I would also like to have a menu item that is
>> possible to delete the point that I have plotted.
>>
>>
>> --
>> Best regards,
>> Dave Colliver.
>>
http://www.AshfieldFOCUS.com >> ~~
>>
http://www.FOCUSPortals.com - Local franchises available
>> "dbgrick" <dbgrick@discussions.microsoft.com> wrote in message
>> news:5F2C9A5C-7547-4E45-A8CA-ED0A28DD1AB9@microsoft.com...
>>> The picturebox has a MouseDown event handler. Wire up the MouseDown
>>> event
>>> handler and then use the x and y coordinates in the MouseEventArgs to
>>> determine the location of the stylus on the graph. Then you create a
>>> form
>>> that contains the info and show it to the user.
>>>
>>> Regards,
>>> Rick D.
>>>
>>> "David" wrote:
>>>
>>>> Hi all,
>>>>
>>>> I have a picturebox control, that I am dynamically generating a graph
>>>> of
>>>> points (vector drawing).
>>>>
>>>> Now, what I need to do is when I hold my pointer on a plotted point (or
>>>> within a specified radius), I want to pop-up certain information about
>>>> the
>>>> point. You know, like the circle that spins up and looks like a right
>>>> click... I want to be able to do something like this.
>>>>
>>>> Any pointers would be appreciated.
>>>>
>>>> Thanks.
>>>> --
>>>> Best regards,
>>>> Dave Colliver.
>>>>
http://www.AshfieldFOCUS.com >>>> ~~
>>>>
http://www.FOCUSPortals.com - Local franchises available
>>>>
>>>>
>>>>
>>
>>
>
>