Examlex

Solved

Import Javax.swing.*; Import Java.awt.*;

question 8

Essay

import javax.swing.*;
import java.awt.*;
public class JDemoBorderLayout extends JFrame
{
private JButton nb = new JButton("North Button");
private JButton sb = new JButton("South Button");
private JButton eb = new JButton("East Button");
private JButton wb = new JButton("West Button");
private JButton cb = new JButton("Center Button");
private Container con = getContentPane();
public JDemoBorderLayout()
{
con.setLayout(new BorderLayout());
_________________________________________
_________________________________________
_________________________________________
_________________________________________
_________________________________________
setSize(400, 150);
}
public static void main(String[] args)
{
JDemoBorderLayout frame = new JDemoBorderLayout();
frame.setVisible(true);
}
}
Using the above code, write the statements in the shaded lines provided to add components to each of the five regions (north, south, east, west and center).


Definitions:

Cost Method

An accounting method used to record investments, where the investment is recorded at its acquisition cost without adjusting for changes in market value.

Investment Account

An Investment Account is a financial account held by an investor with a brokerage firm, bank, or custodian that holds securities and other investments.

Net Income

The total profit of a company after all expenses and taxes have been deducted from revenue.

Dividends

Payments made by a corporation to its shareholder members, typically in the form of cash or additional shares.

Related Questions