Home > Back-end >  Com. Sun. Java swing. Plaf. Nimbus. NimbusLookAndFeel this lack
Com. Sun. Java swing. Plaf. Nimbus. NimbusLookAndFeel this lack

Time:10-23

Java. Lang. ClassNotFoundException: com. Sun. Java swing. Plaf. Nimbus. NimbusLookAndFeel
The at Java. The base/JDK. Internal. Loader. BuiltinClassLoader. LoadClass (BuiltinClassLoader. Java: 583)
The at Java. The base/JDK. Internal. Loader. ClassLoaders $AppClassLoader. LoadClass (ClassLoaders. Java: 178)
The at Java. The base/Java. Lang. This. LoadClass (521). This Java:
The at Java. The base/Java. Lang. Class. ForName0 (Native Method)
The at Java. The base/Java. Lang. Class.forname (415) Class. Java:
The at Java desktop/javax.mail. Swing. SwingUtilities. LoadSystemClass (SwingUtilities. Java: 2036)
The at Java desktop/javax.mail. Swing. UIManager. SetLookAndFeel (UIManager. Java: 632)
At the test. One. & lt; init> (One. Java: 17)
At the test. One. The main (One Java: 10)

Newly installed jdk12, want to try to change the skin, suggesting the above error

The enclosed code:
Public class One extends JFrame {

Public static void main (String [] args)
{
The new One ();

}

One () {
Try {
UIManager
SetLookAndFeel (" com. Sun. Java. Swing. Plaf. Nimbus. NimbusLookAndFeel ");
} the catch (Exception e) {
e.printStackTrace();
}
Enclosing setSize (1320, 750);
this.setVisible(true);
Enclosing setLocationRelativeTo (null);
Enclosing setDefaultCloseOperation (EXIT_ON_CLOSE);
}
}

CodePudding user response:

Want to know what is wrong, how to modify, troublesome everybody a great god

CodePudding user response:

Not import the jar package, it is suggested that setting idea automatically download the jar package
  • Related