Methods to create a FrameBy - AWT and Swing

Q.  These two ways are used to create a Frame

By creating the object of Frame class (association)
By extending Frame class (inheritance)

- Published on 19 Oct 15

a. True
b. False

ANSWER: True
 

    Discussion

  • Nirja Shah   -Posted on 15 Dec 15
    - The above statement is true.

    - They are the ways to create a frame.

    - There are two ways to create a frame:
    1. By creating the object of Frame class (association)
    2. By extending Frame class (inheritance)

    - The code of swing can be written inside the main(), constructor or any other method.

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)