Hi Chaithanya,
Why not make use of reflection? Have a look at the following:
Reflection (C# Programming Guide)
Reflection in C# Tutorial[
^]
[UPDATE]
Okay, I have created two forms. From form1 I will make use of Reflection to call form2. Make use of the fully qualified name of the form. Thus, your proc must return the fully qualified name...
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
Assembly assem = Assembly.GetEntryAssembly();
Form createInstance = (Form)Activator.CreateInstance(assem.GetType("WindowsFormsApplication1.Form2"));
createInstance.ShowDialog();
}
}
[UPDATE]
Kind regards,