A good answer might be:See below: | |
|
public class Repeater extends Frame implements ActionListener
{
Label inLabel = new Label( "Enter Your Name: " ) ;
TextField inText = new TextField( 15 );
Label outLabel = new Label( "Here is Your Name :" ) ;
TextField outText = new TextField( 15 );
Repeater() // constructor
{
setLayout( new FlowLayout() ); // choose the layout manager
add( inLabel ) ;
add( inText ) ;
add( outLabel ) ;
add( outText ) ;
inText.addActionListener( this );
outText.setEditable( false );
}
. . . . . .
}
|
The background color of the frame is white. Say that you want the background color to be green.
(Review: ) Insert a statement into the program that will set the background color to green.
Click Here after you have answered the question