Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Does anyone have a good knowledge of MDI ?

Here is a question:

 

When i need to open a new form in a parent form i use this line

 

Assume parent form is Form1

 

sub button_click (button in Form1)

 

Dim fo As New Form2

fo.MdiParent = Me

fo.show

 

I can do this when i'm creating the new instance of Form2 whithin the parent Form.

When i need to create the instance of Form2 and set to it that the parent will be Form1, from a module or another Form, how can i do that ?

 

Ex.

Module Module1

 

public sub openform

 

Dim fo As New Form2

fo.MDIParent = ?????

fo.show

 

Note: Form1 is the starting Form so no instance is being set.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...