I'm working on a basic program and I've tried adding a working webBrowser component to, in order to give the user more flexibility and be able to browse certain web-sites from within the program, however I've run into a problem I can't get ahead of.
Most modern websites have some dependencies with the new browsers, for example if you visit youtube from within a webBrowser component it tells you to upgrade to a more modern browser. There are other website issues as well such as transparency issues, bitmap problems, missing or missplaced layout, and whatnot. For example visitting StackOverflow with a webBrowser component makes the website rather odd looking, and the logo is not tansparent.
I used this code to bring up a web browser in a window:
this->webBrowser1->Dock = System::Windows::Forms::DockStyle::Fill;
this->webBrowser1->Location = System::Drawing::Point(0, 0);
this->webBrowser1->MinimumSize = System::Drawing::Size(20, 20);
this->webBrowser1->Name = L"webBrowser1";
this->webBrowser1->Size = System::Drawing::Size(823, 587);
this->webBrowser1->TabIndex = 0;
this->webBrowser1->Url = (gcnew System::Uri(L"http://www.google.com", System::UriKind::Absolute));
And this code to navigate to a certain website upon button click after a website was entered in a text field:
private: System::Void toolStripButton1_Click(System::Object^ sender, System::EventArgs^ e) {
webBrowser1->Navigate(toolStripTextBox1->Text);
}
My question is, how do you fix these dependencies? Is there a problem with the Visual Studio itself? (Since I'm using the 2008 version) Or does it use the IE7 options by default? If so, how can you fix it so websites load properly and work as intended?