Logo 
Search:

Java Answers

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds
  Question Asked By: James Rivera   on Feb 20 In Java Category.

  
Question Answered By: Kyle Fox   on Feb 20

I tried your code out.
I had to add some import statements to get it to compile:

import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

class PasswordBox extends JFrame


I invoked the class  from another java source as follows:
import javax.swing.*;

public class Test extends JFrame{

public Test(){

}

public static void main (String[] args){
Test test = new Test();
test.init();
}


public void init(){
PasswordBox box = new PasswordBox();
box.show();
}


}

Share: 

 

This Question has 1 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on actionListener Or get search suggestion and latest updates.


Tagged: