Domanda

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 ?

È stato utile?

Soluzione

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. ;-)

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top