hi,
i am trying to develop an mdi style system so that one parent form holds all child forms. I think i have set up the mdi form correctly, but i cant get some forms to open inside the mdi.
for instance i have a main menu form that does open in the mdi, which has buttons on it which i want to link to other pages. with the code below i have placed on the buttons, the form opens a new window.
i think i may be missing some code assigning the mdiarent but am unsure - the mdi parent form is called mdiCAR.
Thanks, alex
i am trying to develop an mdi style system so that one parent form holds all child forms. I think i have set up the mdi form correctly, but i cant get some forms to open inside the mdi.
for instance i have a main menu form that does open in the mdi, which has buttons on it which i want to link to other pages. with the code below i have placed on the buttons, the form opens a new window.
Code:
Private Sub btnRaiseCar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnRaiseCar.Click
Dim frmCar As New frmCar
With frmCar
.Text = "Child " & Me.MdiChildren.GetLength(0)
.WindowState = FormWindowState.Normal
.ControlBox = True
.Show()
End With
End Sub
i think i may be missing some code assigning the mdiarent but am unsure - the mdi parent form is called mdiCAR.
Thanks, alex