[Mono-dev] Re: Error :: Cannot Find the file specified.

Carlos Solorzano carlos at applianz.com
Thu Apr 13 09:16:17 EDT 2006


My guess is the problem is that "echo world" is not an app that  
exist, however "echo" does exist. Try doing .Start("echo","world"),  
this will call "echo" and pass "world" as an argument. Also some apps  
sometimes don't work unless you use shell execute but I have no idea  
if thats the case for "echo".

--Carlos

On Apr 13, 2006, at 7:20 AM, conn intel wrote:

> Hello friends,
>
> Few updates :
>
> When i am compiling the following program it works ::
>
> using System;
> class HelloWorld
> {
>     public static void Main()
>     {
>         Console.WriteLine("Hello World !");
>         System.Diagnostics.Process.Start("echo world");
>     }
> }
>
> But when i am using the same above System.Diagnostics.Process.Start 
> () function it gives me the following error :
> System.ComponentModel.Win32Exception: Cannot find the specified file
> in <0x00185> System.Diagnostics.Process:Start_shell  
> (System.Diagnostics.ProcessStartInfo startInfo,  
> System.Diagnostics.Process process)
>
> in <0x0006e> System.Diagnostics.Process:Start_common  
> (System.Diagnostics.ProcessStartInfo startInfo,  
> System.Diagnostics.Process process)
> in <0x0002e> System.Diagnostics.Process:Start  
> (System.Diagnostics.ProcessStartInfo
>  startInfo)
> in <0x00022> System.Diagnostics.Process:Start (System.String fileName)
>
> So please guide me where i am wrong.
>
> Thank You in Advance.
>
> Have a NIce time and good day ahead..
> Regards,
>
> Ankur.
>
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list




More information about the Mono-devel-list mailing list