cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

jar file is not working in windows 10

sdibakar
4-Participant

jar file is not working in windows 10

-My code is used to create and Update the environment path using java with Netbeans and cmd prompt. That is working fine in my output console, BUt when i convert it into jar file that is not working properly. what should i do to work on windows 10. Because it's Working Fine in Windows8 & WIndows7.. Thanks in Advance...




Runtime rt = Runtime.getRuntime();
  
String CreoPath_textfield = Textfield.getText();  
  
try {
  rt
.exec(new String[]{"CMD.exe", "/C", "setx CREO_PATH \""+CreoPath_textfield+""});  
  
} catch (IOException ex) {
  
Logger.getLogger(Environment_set.class.getName()).log(Level.SEVERE, null, ex);
  
}
 
if(CreoPath_textfield.equals(""))
  
{
  
JOptionPane.showMessageDialog(null, "<html><b><font color=red>"+"Please enter Your Creo Path" + "</font></b></html>","Error", JOptionPane.ERROR_MESSAGE);
  
}
  
else{
  setVisible
(false);
  
}

0 REPLIES 0
Top Tags