Is it possible to get the position of the child form in the framing coordinates? If yes, please tell me how to do it.

    1 answer 1

    Let your MDI form be called fmMDI , then fmMDI.Location.X and fmMDI.Location.Y will indicate the position of the upper left corner of the MDI form relative to the parent.

    It is checked simply: put 2 labels on your MDI form and write this form in the handler of the LocationChanged event write:

      private void fmMDI_LocationChanged(object sender, EventArgs e) { label1.Text = "X = " + this.Location.X; label2.Text = "Y = " + this.Location.Y; } 

    Then, if the parent form is not expanded to full screen and moved around the screen, then wherever and how we did not move the parent, the movement of the child MDI form will still be relative to the coordinates of the parent.