T
Tomas Andersson
I have a project with Form1
this form has a menu that opens a new child form called RotorTest
THe form Rotortest is opened as a MDI childform
Private Sub RotorToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles RotorToolStripMenuItem.Click
Dim NewMDIChild2 As New RotorTest
NewMDIChild2.MdiParent = Me
NewMDIChild2.Show()
End Sub
In the form RotorTEst there is a groupbox with a listbox and a button
Pressingf the button opens a sub in another module and runs a mysql query
the query loops and is supposed to add the DB information to the listbox.
Dim DR As MySqlDataReader = cmd.ExecuteReader
If DR.HasRows Then
DR.Read()
While (DR.Read())
RotorTest.SearchWindow.Items.Add(CStr(DR.GetString("ID"))
End While
End If
DR.Close()
Nothing i s added to the listbox.
Im guessing that I need to reference the specific childform but how do I do
this???
this form has a menu that opens a new child form called RotorTest
THe form Rotortest is opened as a MDI childform
Private Sub RotorToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles RotorToolStripMenuItem.Click
Dim NewMDIChild2 As New RotorTest
NewMDIChild2.MdiParent = Me
NewMDIChild2.Show()
End Sub
In the form RotorTEst there is a groupbox with a listbox and a button
Pressingf the button opens a sub in another module and runs a mysql query
the query loops and is supposed to add the DB information to the listbox.
Dim DR As MySqlDataReader = cmd.ExecuteReader
If DR.HasRows Then
DR.Read()
While (DR.Read())
RotorTest.SearchWindow.Items.Add(CStr(DR.GetString("ID"))
End While
End If
DR.Close()
Nothing i s added to the listbox.
Im guessing that I need to reference the specific childform but how do I do
this???