Hi All, I have a Java file,which when I compiled, I will be able to see only first 100 errors on console after that java compiler(javac) exits. How will I be able to see all the compilation errors on console? Thanks in advance- opensid
Generally the compiler will give up after 100 errors. Most of the errors after this point will likely be caused by one of the first errors. If you must have more errors check out the javac options -Xmaxerrs
and -Xmaxwarns
Have you tried the -Xmaxerrors command line option? go here and search for "maxerrors"
If you are using Windows operating system then try to compile your sources using Command Prompt. Then that command prompt won't exit on errors.
If you're using Eclipse, Preferences > Java > Compiler > Building > General
will let you specify more problems per unit.
Perhaps a bit more work than -Xmaxerrors, but you could capture the full stack trace as a string and then do what you wish with it...
See the example here... http://www.java2s.com/Code/Java/Language-Basics/ConvertanexceptiontoaStringwithfullstacktrace.htm