Using MDI Parents
Do you need something made? then ask in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
3 posts
Page 1 of 1
Hello,
I was inspired to make a program like B++ after I saw agust1337's post. I am using a PropertyGrid to edit the controls. In a timer event, I want the NumericUpDown's max value to go to the amount of controls in the current MDI Child. Then, I want the PropertyGrid to have the selected item's properties. I want the user to be able to change the properties of a control added at runtime on the open MDI Child in a PropertyGrid.
~GoodGuy17
I was inspired to make a program like B++ after I saw agust1337's post. I am using a PropertyGrid to edit the controls. In a timer event, I want the NumericUpDown's max value to go to the amount of controls in the current MDI Child. Then, I want the PropertyGrid to have the selected item's properties. I want the user to be able to change the properties of a control added at runtime on the open MDI Child in a PropertyGrid.
~GoodGuy17

You could always just set the numericupdown's maximum in the MdiChildActivate event.
Check out:
Check out:
Code: Select all
Dim pg As PropertyGrid = New PropertyGrid()
Private Sub MDIParent1_MdiChildActivate(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.MdiChildActivate
NumControlIndex.Maximum = Me.ActiveMdiChild.Controls.Count - 1
End Sub
Private Sub NumControlIndex_ValueChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles NumControlIndex.ValueChanged
Dim childIndex As Integer = Array.IndexOf(Me.MdiChildren, Me.ActiveMdiChild)
If childIndex > -1 Then
pg.SelectedObject = Me.MdiChildren(childIndex).Controls(Convert.ToInt32(NumControlIndex.Value))
End If
End Sub
Thank you mandai, I am going to set up another request for listboxes and reading from file. Take a look if you like.
3 posts
Page 1 of 1
Copyright Information
Copyright © Codenstuff.com 2020 - 2023