multiple sdi form communcation

  • Thread starter Thread starter Matt
  • Start date Start date
M

Matt

I have one sdi form that instantiates the other. I am trying to figure out
how to make the second form feedback information to the first after the user
enters it on the second form. I was thinking I should use callbacks but I
can't seem to see how. does anyone have a better idea or some sample code
for using callbacks for this task?

Thanks in advance
 
Matt,

You have a number of options available to you. The first would be to
pass a reference of the parent form to the child (through the constructor,
or by setting a property, or calling a method). Then, the child form can
call methods on the creator.

The other option you have is to have the child form expose events which
will be handled by the form that created the child form. This would lead to
greater decoupling between the two, and is the better solution, in my
opinion.

Hope this helps.
 
Back
Top