• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

dos prompt + java progaram + problem

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hey guys:
i m running a java program (jms client) that i start using a .exe batch file. The program opens in a dos-command prompt and prints on the window messages it receives..the problem now is that whenever we have some text highlighted on the dos window the whole java program freezes...and again when we hit enter(disabling/removing the white space) all messages get printed out at once..so when we have highlighted text the whole dos window freezes & waits for a enter to flush all output...is there a workaround..this is not a java code problem..but is inherent in all dos windows..thanks in advance for help
 
Ranch Hand
Posts: 808
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What if you wrote to a text file instead of the DOS window? Then you could do whatever you want with the text.
 
author and iconoclast
Posts: 24207
46
Mac OS X Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is indeed a fix. It's called "Linux".

Seriously: there used to be, and probably still are, alternative Windows command shells available as freeware/shareware; search around, see what you can find. Alternatively, you can change your program to use a graphical console (i.e., a JTextArea in a JFrame) instead of writing to System.out.
 
Ranch Hand
Posts: 4982
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

What if you wrote to a text file instead of the DOS window? Then you could do whatever you want with the text.


I agree with Jeff, you might either write the messages to the LOG file in the file system, or create a GUI console for message display, instead of making use of the standard output.

Nick
 
Ranch Hand
Posts: 3061
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Ernest Friedman-Hill:
There is indeed a fix. It's called "Linux".


Here! Here!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic