Win32Exception: ApplicationName=‘CompressionBundle.exe’, CommandLine=‘D:/Download/gameclient_f1/SlotClient/AB/Android/StreamingAssets D:/Download/gameclient_f1/SlotClient/AB/AndroidZips’, CurrentDirectory=‘D:/Download/gameclient_f1/SlotClient/export/Compress/’, Native error= access denied。
By the way ,it work well in unity2018.4.36
my code:
string args = data.assetBundleDir + " " + data.zipBundleDir;
string currDir = Directory.GetCurrentDirectory();
string exedir = Application.dataPath.Replace(“Assets”, “”) + “export/Compress/”;
//string exedir = Application.dataPath + “/Compress/”;
Directory.SetCurrentDirectory(exedir);
System.Diagnostics.ProcessStartInfo info = new System.Diagnostics.ProcessStartInfo();
info.FileName = “CompressionBundle.exe”;
info.Arguments = args;
info.WindowStyle = System.Diagnostics.ProcessWindowStyle.Normal;
info.UseShellExecute = false;
info.ErrorDialog = true;
info.CreateNoWindow = true;
info.WorkingDirectory = exedir;
using (System.Diagnostics.Process pro = System.Diagnostics.Process.Start(info))
{
pro.WaitForExit();
while (!pro.HasExited)
{
}
if (pro.ExitCode != 0)
{
Debug.LogError("Failed running " + args + “\n\n” + pro.StandardError.ReadToEnd());
}
pro.Close();
}