Manage MDI childs
-
hello! i've created a small mdi sofware and.to open a child form a user should click on the menu item corresponding.Even if the same form is already openned when i click on the same menu item it opens again the ssame form which is not logical.How can i prevent the form to be openned more than once.thanks
eager to learn
-
hello! i've created a small mdi sofware and.to open a child form a user should click on the menu item corresponding.Even if the same form is already openned when i click on the same menu item it opens again the ssame form which is not logical.How can i prevent the form to be openned more than once.thanks
eager to learn
-
I haven't work in VB for a while, so I apologize if my syntax is off. What you should do is something along the lines of:
Dim myForm as New Form1() myForm.Show()
Hi J$ Your code do the same thing, and the problem remains same do this .show did not create the new object for the form else ti will display the form again and again With Regards Yogesh Agarwal
-
hello! i've created a small mdi sofware and.to open a child form a user should click on the menu item corresponding.Even if the same form is already openned when i click on the same menu item it opens again the ssame form which is not logical.How can i prevent the form to be openned more than once.thanks
eager to learn
-
Create a object of the form (probably in a module)- For e.g Dim objfrm1 as Form1 Now, on click event of the context menu (or button) write the following code - if isnothing(objfrm1) then objfrm1 = new form1 objfrm1.MdiParent = me objfrm1.show() else objfrm1.focus() end if Also, do not forget to set the obj to nothing on the form closing event. I mean, on CLOSING event of form1 write the followng code. objfrm1 = nothing Worring about losing keeps me WINNING>>..
-
hello! i've created a small mdi sofware and.to open a child form a user should click on the menu item corresponding.Even if the same form is already openned when i click on the same menu item it opens again the ssame form which is not logical.How can i prevent the form to be openned more than once.thanks
eager to learn
Hi try this dim frm as form1 frm.showdialogue(me) this wont let the user work with anything other form, until this form closes! hope this helps...
-
Hi try this dim frm as form1 frm.showdialogue(me) this wont let the user work with anything other form, until this form closes! hope this helps...
-
Create a object of the form (probably in a module)- For e.g Dim objfrm1 as Form1 Now, on click event of the context menu (or button) write the following code - if isnothing(objfrm1) then objfrm1 = new form1 objfrm1.MdiParent = me objfrm1.show() else objfrm1.focus() end if Also, do not forget to set the obj to nothing on the form closing event. I mean, on CLOSING event of form1 write the followng code. objfrm1 = nothing Worring about losing keeps me WINNING>>..