Respondida Open WPF window at cursor position

  • jueves, 09 de febrero de 2012 9:05
     
      Tiene código

    I would like to open a WPF window on top of a model at cursor position, e.g. ondoubleclick.

    How do i get the correct position. I´ve tried this:

    [DllImport("user32.dll")]
    private static extern bool GetCursorPos(ref Point lpPoint);

    When i set the postion of the WPF window to these coordinates, it is relative to the cursor, but half a screen away from the cursor. I can though get the cursor position relative to the Modelwindow, but this won´t me help either, because i need the absolute position...

    Any idea?

    Jakob

Todas las respuestas

  • viernes, 13 de abril de 2012 9:07
    Propietario
     
     Respondida

    We're sorry your question hasn't received an answer.

    Having reviewed the open questions on the forum, we have marked all unanswered questions older than sixty days as closed.

    If this is still an issue for you, please re-activate or re-ask the question. Thank you.