Home All Groups Group Topic Archive Search About

Open form and run event/sub

Author
4 Apr 2005 2:07 PM
JAG711
How can I open a MDI childform from it's parent form and then programmically
run an event or procedure from the childform.  ie.  run the click event code
of the child form's command button.

Author
4 Apr 2005 2:17 PM
Peter Proost
Hi create a public sub on the child form with the code you want to see
executed, and then do something like this where you want to call the child
form (for example menu click on parent form)

dim objChild as new YourchildForm
objChild.MdiParent = me
objChild.Show
objChild.YourPublicSub

Hth peter


Show quoteHide quote
"JAG711" <JAG***@discussions.microsoft.com> schreef in bericht
news:5057B6A8-E63F-4D98-8CCB-FC4C18E9CC11@microsoft.com...
> How can I open a MDI childform from it's parent form and then
programmically
> run an event or procedure from the childform.  ie.  run the click event
code
> of the child form's command button.