Actually, ShellExecuteEx is called from the Start->Run dialog (and most other places except the console). If an IShellExecuteHook has been installed, then it is allowed to intercept the ShellExecuteEx and handle it.
By default, a "URL Exec Hook" (AEB6717E-7E19-11d0-97EE-00C04FD91972) is installed which handles URLs. I find it difficult to believe that Process.Start does not use ShellExecuteEx. Richard Semi-related article: http://www.codeproject.com/csharp/dateparser.asp > -----Original Message----- > From: Moderated discussion of advanced .NET topics. > [mailto:[EMAIL PROTECTED]]On Behalf Of Ian Griffiths > Sent: 07 October 2002 12:24 > To: [EMAIL PROTECTED] > Subject: Re: [ADVANCED-DOTNET] Can't use Process.Start from a WinForms > app. launched via http?? > > > When you run http://www.microsoft.com/ from the Run dialog, > you're actually > launching IEXPLORE - the dialog appears to know all about URLs and treat > them specially. This may explain why it doesn't work, where cmd does (cmd > is a real program). > > I suspect that System.Diagnostics.Process.Start is working at a > lower level > than Start->Run. > > Have you tried launching a URL for something that is a program? The > canonical example would appear to be: > > http://www.sellsbrothers.com/wahoo/wahoo.exe > > > -- > Ian Griffiths > DevelopMentor > > ----- Original Message ----- > From: "Dave Adair" <[EMAIL PROTECTED]> > > > > More info: > > > > I CAN start other processes ok. For example, I can launch > "cmd" and a DOS > > window appears. So the problem appears not to be an issue with trusted > > sites or full-trust on that site but appears to be specific to launching > > Internet Explorer. > > > > So why doesn't this work when the app is launched from http: > > > > System.Diagnostics.Process.Start("http://www.microsoft.com"); > > > > but this does work: > > > > System.Diagnostics.Process.Start("cmd"); > > > > (BTW, if I try to open http://www.microsoft.com from the > Start|Run dialog > > of Windows that works also) > > > > This is the error I get when it does System.Diagnostics.Process.Start > > ("http://www.microsoft.com"): > > > > System.ComponentModel.Win32Exception: The system cannot find the file > > specified > > at > System.Diagnostics.Process.StartWithShellExecuteEx(ProcessStartInfo > > startInfo) > > at System.Diagnostics.Process.Start() > > at System.Diagnostics.Process.Start(ProcessStartInfo startInfo) > > at System.Diagnostics.Process.Start(String fileName) > > > > Is there some other way to launch IE besides the way I'm trying > to do it? > > Or can someone tell me what I'm doing wrong? Thanks. > > You can read messages from the Advanced DOTNET archive, > unsubscribe from Advanced DOTNET, or > subscribe to other DevelopMentor lists at http://discuss.develop.com. You can read messages from the Advanced DOTNET archive, unsubscribe from Advanced DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.