launching IE from within winforms app.

G

Guest

I have a strange error occuring in my winforms app that I can't seem to find any fix for.

With a button click I am launching something like the following:

string url ="http://www.microsoft.com"
System.Diagnostics.Process.Start(url);

Now, it USED to work in my current winforms app. However, now it throws an error everytime when I try to launch this.

It throws: "An unhandled exception of type 'System.ComponentModel.Win32Exception' occurred in system.dll

Additional information: The system cannot find the file specified"

Now, if i start a clean winforms app, and put the same code behind a button click, it works!!

So what's the deal? It seems somehow this project has been compromised, but nothing else is throwing errors or giving me any hints.

Your help is appreciated!
 
C

Cor

Hi Michael,

I have to admit this is a guess

Did you set it in the load event and where all compenents not yet
initialized?

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top