Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Application deployed via ClickOnce failed to start process for external executable

Posted on 2011-09-07
3
Medium Priority
?
723 Views
Last Modified: 2013-12-12
I have a desktop application configured for ClickOnce deployment. The Security Settings is "Full Trust". I have a feature in application that starts new process with another executable and then loads results produced by it into a text file. The logic is following I save input data into file 'input.txt' next I create new process and start it
 using (Process process = new Process())
	        {
	            // Stop the process from opening a new window
	            process.StartInfo.RedirectStandardOutput = true;
	            process.StartInfo.UseShellExecute = false;
	            process.StartInfo.CreateNoWindow = true;
	            process.StartInfo.FileName = graphvizFile;
	            process.StartInfo.Arguments = string.Format("-o \"{0}\" \"{1}\"", outputFilePath, inputFilePath);

	            process.Start();
	            process.WaitForExit();
	        }
	        File.Delete(inputFilePath);

Open in new window


This code does not work in deployed application (via build configuration "Deployment"), but works when I compile project with "Debug" or "Release" build configuration.
0
Comment
Question by:rkharko
  • 3
3 Comments
 
LVL 3

Author Comment

by:rkharko
ID: 36497075
I have now more information - the problem is with one configuration file that does not have extension and is ignored by ClickOnce during deployment and after installation on client machine this config file is messing and executable fails when process.Start().
0
 
LVL 3

Accepted Solution

by:
rkharko earned 0 total points
ID: 36502853
The problem solved by manually editing the *.csproj file to add as content file for deployment this config file (that does not have file extension)
0
 
LVL 3

Author Closing Comment

by:rkharko
ID: 36503168
solved by me
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever run into that annoying problem where the computer won't boot?  Wouldn't it be great if you had a tool that would make that disk boot again?  I have found one tool that works more often than not ...
High user turnover can cause old/redundant user data to consume valuable space. UserResourceCleanup was developed to address this by automatically deleting user folders when the user account is deleted.
The viewer will learn how to successfully download and install the SARDU utility on Windows 7, without downloading adware.
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…

879 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question