最近我尝试做一个多工具的应用程序,但我似乎找不到正确的解决方案。我试过的代码片段不起作用。任何帮助都将不胜感激!
我试过这段代码:
Process.Start($"./necessary/injector.exe");发布于 2022-11-30 22:47:43
我认为Path可能会对你有所帮助。试着做这样的事情:
string dir = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) ?? string.Empty;
string otherDir = Path.Combine(dir, "necessary");
ProcessStartInfo process_start_info = new()
{
WindowStyle = ProcessWindowStyle.Hidden,
FileName = Path.Combine(otherDir, "injector.exe"),
Arguments = "--help"
};
var process = Process.Start(process_start_info);
process?.WaitForExit();https://stackoverflow.com/questions/74632604
复制相似问题