Mouse_Event.java:7: error: cannot access JFrame static JFrame frame; ^ bad source file: .\JFrame.java file does not contain class JFrame Please remove or make sure it appears in the correct subdirectory of the sourcepath. 1 error code example
Example: java create jframe
import javax.swing.JFrame;
public class example {
public static void main(String[] args){
JFrame frame = new JFrame();
frame.setSize(100,100);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOES);
frame.setTitle("Example Frame");
frame.setVisible(true);
}
}