Link to home
Create AccountLog in
Avatar of emi_sastra
emi_sastra

asked on

Second Child Form Keep Showing Like "Find And Replace" Form.

Hi,

I have a windows application with a mdiForm and several child windows forms.
When I open a child form and that child form open another child form.
I want the second child form keep showing when I click the first child form or until I close it.
It is like "Find And Replace" Form.

Thank you.
Avatar of gnoon
gnoon
Flag of Thailand image

Don't make the second form as a mdiForm's child, then show it using .ShowDialog(<<mdiForm's reference>>).
Avatar of emi_sastra
emi_sastra

ASKER

Hi gnoon,

Let say the second child form is "frmPaymentTerm"

Would you please provide code?

At mdiform.
  frmTMSUPPLIER.MdiParent = Me
            frmTMSUPPLIER.Show()

At frmTMSUPPLIER form?
How to call  "frmPaymentTerm" in order to make both it keep showing when switching focus between frmTMSUPPLIER and frmPaymentTerm.

Thank you.
ASKER CERTIFIED SOLUTION
Avatar of gnoon
gnoon
Flag of Thailand image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Ok.

Thank you very much for your help.
Hi gnoon,

Just for your info, your code:
frmPaymentTerm.ShowDialog(Me.MDIParent)

should change to:
frmPaymentTerm.Show(Me.MDIParent)
to make it work.

Thank you.