Вопрос

I want to run specific code with C# windows application on cmd(command prompt) for sign jar file. I used this code

System.Diagnostics.Process.Start(@"cmd", @"/K ""c:\program Files\Java\jdk1.6.0_23\bin\jarsigner.exe"" -keystore filepath.p12 filepath.jar ""alias_name""");

I encountered this error while I executing this code

Error:

'c:\program' is not recognized as an internal or external command,
operable program or batch file.

How can I solve this problem ?

Это было полезно?

Решение

From the comments above, i understand this solves the issue:

System.Diagnostics.Process.Start(@"c:\program Files\Java\jdk1.6.0_23\bin\jarsigner.exe",
    @"-keystore filepath.p12 filepath.jar ""alias_name""");

Happy signing. ;-)

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top