This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Code owrks in Netbeans but the Jar fails to execute the code outside netbeans

 
Will Koester
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So I am writing code to backup and restore some DB files. The code runs fine within Netbeans 7 but after packaging to a jar and running the same code it fails to stop the service and initiate the mysqldump command. I tried several modifications of the code and no change. Another set of eyes would be a great help on this. The first two sections of code are the button action and the SwingWorker. The third section works as a void or boolean within Netbeans just not outside it. I am thinking that this may be a Runtime exec issue but not sure. I tested from command line as well and it still fails to run the program jsut hangs there is no error or indication that it is going through the third section of code from task manager or any other monitoring tool.





 
Mike Zal
Ranch Hand
Posts: 144
Fedora Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know if this is the problem but You should not use Runtime.exec
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic