Click here to Skip to main content
15,897,519 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In my asp.net application i am using class Process from System.Diagnostic...
For example: After client click on web page, on server side starting method
Process.Start("applic.exe", arg);
, but applic.exe NOT YET Starting :(
I trying start it from command-line (cmd) with arg... all working fine...
May be problem with security with IUSR_COMP account or w3wp process ?

Thanks for advice...
Posted

Have you tried passing the full path to your exe?

Is Process.Start throwing an exception? If so, what is it?

If it is a permissions problem, try setting the permissions on the exe, or using the overload that takes a domain, username and password.

Nick
 
Share this answer
 
Have you ever checked your server's task manager after clicking your web page to see whether or not the process have started ;) ? I hope you will find your solution from the following link.

http://support.microsoft.com/kb/555134
 
Share this answer
 
Yes
1) I try full path to .exe - file is found...
2) I try throwing exception... nothing happend
3) exe file placed in shared folder for all users..
4) I try overloaded with username, pass, and domain... nothing happend

Thanks Nick...

P.S. This file, which I try to start actually loaded into memory and is currently working, but I need that when run it executes the commands from the command line...
 
Share this answer
 
Could you provide a small sample program that demonstrates your problem? When you add more info, make sure to edit your original question rather than adding an answer. This seems to work for me:
C#
static void Main(string[] args)
{
	string str = System.Reflection.Assembly.GetEntryAssembly().Location;
	if (args.Length == 0) System.Diagnostics.Process.Start(str, "hello");
	System.Threading.Thread.Sleep(5000);
}

When you run that console application, it will launch a second instance of itself and that second instance will detect the command line argument, which it will interpret as meaning that it should not launch any more instances of itself.
 
Share this answer
 

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