S4E

S4E

  • NA
  • 33
  • 0

Form launch - different behaviour!!

Oct 18 2004 6:20 AM
I've got a c-sharp windows form, and it hosts a webcontrol. The problem is that the form behaves differently depending on how it it loaded... I have tried loading the form in one of two ways: 1. make the form the main application window: [STAThread] static void Main() { Application.Run(new MainFrame()); } 2. load the form via a menu interaction: private void MenuItem_Click(object sender, System.EventArgs e) { MainFrame masForm = new MainFrame(); masForm.MdiParent = this; masForm.Show(); } If I use method 1 the webcontrol will show me a webpage, if I use method 2 it will not work. Can anyone who has any idea why this would make a difference help!! Has anyone used the c:\windows\system32\shdocvw.dll successfully on a form in both such scenarios?

Answers (1)