wood burning stoves 2.0*
The moose likes Java in General and the fly likes Cannot run JAR file under folder which has unicode characters in name Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Cannot run JAR file under folder which has unicode characters in name" Watch "Cannot run JAR file under folder which has unicode characters in name" New topic
Author

Cannot run JAR file under folder which has unicode characters in name

Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 498

Hi all,

If I put my application's JAR file under one of these folders:

- C:\Test\GÖRLITZ\MyApp.jar: It will run if double clicking on the Jar file, but it won't run if I run through Runtime.getRuntime().exe()
- C:\Test\Hay chửa\MyApp.jar: It won't run on either double clicking or calling Runtime.getRuntime().exe()

Looks like the Java launcher doesn't work well with unicode characters in file path.
Please suggest solution/workaround.

Thanks,
Nam


PM Me If You Want to get Urgent Help on Java Programming
Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 498

No one has any ideas?
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

You're looking for workarounds? Then write a batch file with the folder name hard-coded, and run that batch file via Runtime.exec().
Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 498

Paul Clapham wrote:You're looking for workarounds? Then write a batch file with the folder name hard-coded, and run that batch file via Runtime.exec().

Yes, I need a workaround. I will try your suggestion.
Thanks.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Cannot run JAR file under folder which has unicode characters in name
 
Similar Threads
Under Java Security Manager, accessing a file inside a jar
Problem running jar on new Windows 7 install
Run jar file
JAR file class not found exception
Java executable