Hello i have problem i want to open a powershell sciprt, while i use Process.Start everything work, but windows popup for a second, and thats why i want to use ProcessStartInfo, but i make something wrong.
ProcessStartInfo startInfo = new ProcessStartInfo("powershell.exe")
{
UseShellExecute = false,
CreateNoWindow = true,
RedirectStandardOutput = true,
//Arguments = "nologo -WindowStyle Hidden -ExecutionPolicy UnRestricted",
FileName = @"C:\\Users\\Kirlen\\Documents\\temp_skrypt_run.ps1",
};
Process.Start(startInfo);
im getting System.ComponentModel.Win32Exception: while try to run it
i would like to ask for help to fix that code