1,HTML source code£º <html> <head> <title>How to use ClassNotFoundException</title> </head> <body> <script src="jsjava.js"></script> <script> var c; try{ c=Class.forName("ClassNotFoundException777"); }catch(e){ document.write(e.message); } if(c){ var instance=c.getConstructor([Integer,String]).newInstance([0,"This is an error!"]); document.write(instance.message); } </script> </body> </html> 2,The display:

Class ClassNotFoundException777 is not found!