Help me to Show a form in VB.net
-
In my project i have to show a form using a string variable, that means the form name is available in a string variable like, strFormToShow = "Form2" and form2 is available in my project. How can i show this form2 using this string variable ? pls help me, urgent regards ajo:(
-
In my project i have to show a form using a string variable, that means the form name is available in a string variable like, strFormToShow = "Form2" and form2 is available in my project. How can i show this form2 using this string variable ? pls help me, urgent regards ajo:(
First rethink your pbolem. Is this really the way you would like to open forms? I smell a bad design :) But anways, look at Reflection, that should be the solution for your problem. -------------------------------------------------------- My development blog Q:What does the derived class in C# tell to it's parent? A:All your base are belong to us!
-
In my project i have to show a form using a string variable, that means the form name is available in a string variable like, strFormToShow = "Form2" and form2 is available in my project. How can i show this form2 using this string variable ? pls help me, urgent regards ajo:(
I agree with CWIZO. There's NEVER a reason to tie data directly to the names of objects in your code. This reeks of a bad design waiting to explode in your face. Dave Kreskowiak Microsoft MVP - Visual Basic