Click here to Skip to main content
15,897,371 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Good afternoon,

I'm building an autopatcher for a game.
The programs works like this.
The main form (Form1) updates and when it's over calls Form2 (whcic is the menu with buttons and such)
In form 2 i've created the shown event that displays a website

C#
private: System::Void shown1(System::Object^  sender, System::EventArgs^  e)
         {
             String^ aux2=gcnew String(d->registo);
             this->webBrowser1->Navigate(aux2);
         }


with d->registo = "www.metin2.pt"

If the website is metin2.pt i get this error when loading the website

An unhandled exception of type 'System.AccessViolationException' occurred in System.Windows.Forms.dll

Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.


BUT if the website is google.pt the webbrower load's it normally.

How can i fix this?
Posted
Updated 7-Sep-11 6:32am
v2
Comments
Emilio Garavaglia 7-Sep-11 12:32pm    
retagged as C++/CLI

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900