简体   繁体   中英

How do I open a Java console for an application already running?

I'm not sure if this is possible or not, but I have an application running that has failed in an unusual way, and I now want to see the console. Is it possible to open the Java console once an application is already running? If so, how (on Windows 7)?

Agree with AlexR. I would use something like log4j to do your logging. Saves a LOT of hassle.

If your application does not have console on windows it was executed using javaw that does not have console by definition.

Try to use logs or JMX to debug your problem.

I don't think you can.

What you can do is run your application from the Command Prompt and check for the errors appearing.
The best solution is to try to run your application from Eclipse or Netbeans so you can have a better understanding of the error causing your application to fail.

PS : Eclipse and Netbeans are free to use.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM