Click here to Skip to main content
15,867,568 members
Home / Discussions / C#
   

C#

 
AnswerRe: Equation on c# Pin
Richard MacCutchan3-Oct-12 21:41
mveRichard MacCutchan3-Oct-12 21:41 
QuestionImplementing Private Inheritence Pin
AmbiguousName3-Oct-12 19:07
AmbiguousName3-Oct-12 19:07 
AnswerRe: Implementing Private Inheritence Pin
Peter_in_27803-Oct-12 19:21
professionalPeter_in_27803-Oct-12 19:21 
GeneralRe: Implementing Private Inheritence Pin
AmbiguousName3-Oct-12 19:33
AmbiguousName3-Oct-12 19:33 
GeneralRe: Implementing Private Inheritence Pin
Peter_in_27803-Oct-12 19:50
professionalPeter_in_27803-Oct-12 19:50 
AnswerRe: Implementing Private Inheritence Pin
Pete O'Hanlon3-Oct-12 22:19
subeditorPete O'Hanlon3-Oct-12 22:19 
AnswerRe: Implementing Private Inheritence Pin
jschell4-Oct-12 11:39
jschell4-Oct-12 11:39 
Questionprocess being called by C# app Pin
rachel_m3-Oct-12 18:28
rachel_m3-Oct-12 18:28 
In a C# 2008 application, I have a foreach loop that is listed below:
for each (PkgID in PkgIDs) 
  {
Process eProcess = new Process();
 String Process_Arguments = null;
 eProcess.StartInfo.UseShellExecute = false;
 eProcess.StartInfo.FileName = strConsoleAppLocation;
 Process_Arguments = filedirectorypath + " 7654" + PkgID;
 eProcess.StartInfo.Arguments = Process_Arguments;
 eProcess.Start();
 eProcess.WaitForExit(1800);
 eProcess = null;
 Process_Arguments = null;
}

As you can see from the code I listed above I have the following questions:
1. For each iteration of the for loop I create a new process object called eProcess and then I set
eProcess = null;
near the end of the loop.
Thus can you tell me if this is code or not and why? If you have better code that I could use would you tell me what you recommend by pointing me to some code I can use as a reference?
2. You can see that I also have the following line of code,
eProcess.WaitForExit(1800);

I have this line since the process that is being called does not seem to complete its processing before the control is returned to this program.
Thus can you tell me the following:
a. Is the number of milliseconds that I specify a good amount? Can you tell me why or why not?
b. Since the code is returned to this calling program before the entire eProcess finished, can you tell me if this is a good way to wait for the eprocess to finish? I would think there is a better way to what for eProcess to finish. If so, is there a way to tell when the eProcess
is really finished executing?
AnswerRe: process being called by C# app Pin
Smart Arab3-Oct-12 20:54
Smart Arab3-Oct-12 20:54 
QuestionFail Read Int64 value from binary file created by C++ Pin
kisetsu3-Oct-12 14:49
kisetsu3-Oct-12 14:49 
QuestionThere is an error in XML document calling a PHP Webservice Pin
RalphGielkens3-Oct-12 10:54
RalphGielkens3-Oct-12 10:54 
QuestionPassing object[] Elements as Parameters to Invoke() Pin
ezazazel3-Oct-12 7:04
ezazazel3-Oct-12 7:04 
AnswerRe: Passing object[] Elements as Parameters to Invoke() Pin
Matt T Heffron3-Oct-12 9:08
professionalMatt T Heffron3-Oct-12 9:08 
GeneralRe: Passing object[] Elements as Parameters to Invoke() Pin
ezazazel3-Oct-12 19:26
ezazazel3-Oct-12 19:26 
QuestionC# calling executable Pin
dcof3-Oct-12 3:57
dcof3-Oct-12 3:57 
AnswerRe: C# calling executable Pin
Pete O'Hanlon3-Oct-12 4:16
subeditorPete O'Hanlon3-Oct-12 4:16 
AnswerRe: C# calling executable Pin
Shameel3-Oct-12 4:51
professionalShameel3-Oct-12 4:51 
AnswerRe: C# calling executable Pin
Dave Kreskowiak3-Oct-12 5:35
mveDave Kreskowiak3-Oct-12 5:35 
GeneralRe: C# calling executable Pin
dcof3-Oct-12 8:07
dcof3-Oct-12 8:07 
GeneralRe: C# calling executable Pin
Pete O'Hanlon3-Oct-12 8:38
subeditorPete O'Hanlon3-Oct-12 8:38 
GeneralRe: C# calling executable Pin
Dave Kreskowiak3-Oct-12 13:45
mveDave Kreskowiak3-Oct-12 13:45 
QuestionC# Windows application not responding after 30 minutes Pin
sujithkumarsl2-Oct-12 10:13
sujithkumarsl2-Oct-12 10:13 
AnswerRe: C# Windows application not responding after 30 minutes Pin
Smart Arab2-Oct-12 10:58
Smart Arab2-Oct-12 10:58 
AnswerRe: C# Windows application not responding after 30 minutes Pin
Dave Kreskowiak2-Oct-12 12:35
mveDave Kreskowiak2-Oct-12 12:35 
GeneralOT Pin
Peter_in_27802-Oct-12 22:08
professionalPeter_in_27802-Oct-12 22:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.