i
Hallo,
m using MDIContainer.
1. How can i pass the varaible from parent to child ?
2.How can i prohibited to open more than 1 window with the same Name (That means in my MenuStrip there are Ordre,Tarif,Config… when user already open the Ordre, when he click the menustrip ordre again, it not open a new window/created a new child but pointed to the ordre window that already open) ?
Thanx before.
Create a private, protected or public member in your mdicontainer window:
And here is the mdi child:
In the example above we use two fields, each one for the two classes, property for storing the var in the MDI parent, and method in child for making a communication on the variable and storing a copy inside the child.
This is useful for parent to child, but it should be implemented in different way for parent to many children with synchronization.