how to delay execution in c#
int sleepTime = 1000; // in mills
Task.Delay(sleepTime).Wait();
// or
Thread.Sleep(sleepTime);
how to delay execution in c#
int sleepTime = 1000; // in mills
Task.Delay(sleepTime).Wait();
// or
Thread.Sleep(sleepTime);
c# start process and wait for exit code
public virtual bool Install(string InstallApp, string InstallArgs)
{
System.Diagnostics.Process installProcess = new System.Diagnostics.Process();
//settings up parameters for the install process
installProcess.StartInfo.FileName = InstallApp;
installProcess.StartInfo.Arguments = InstallArgs;
installProcess.Start();
installProcess.WaitForExit();
// Check for sucessful completion
return (installProcess.ExitCode == 0) ? true : false;
}
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us