Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Receive a variable from another file or batch file

 
matt prowell
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you have a jframe receive a variable from another program that is going to execute the jar file. Any ideas please. Thanks
 
matt prowell
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maybe i should reword this some. Another program is going to be lauching my jframe. I want it to take a number from the program that is lauching it and use it to lookup something.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You'd do it just like launching any java application.

java.exe program [arguments]

Your main method already accepts a String[] array which gets populated with the argumnets specified on the command line.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!