Application with multi screens - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Application with multi screens

RibbletonRibbleton Posts: 152Member
I've just got my 3rd assignment and a little confused about how to attempt it. I have to create 3 screens
I have to create a Menu Screen
Add Question Screen (this will be attached to a MS access database and write to the database)
Take Test Screen ( this will read the ms access database to present questions to the user)

my problem is, Do i create a seperate class for each screen and extend JFrame for each class.

so i'd have

public class Menu extends JFrame{}
class AddQues extends JFrame {}
class Test extends JFrame {}

Or do i just use one screen and write over it each time i change screen.

Thanks for your help.

Comments

  • forlogforlog Posts: 7Member
    : I've just got my 3rd assignment and a little confused about how to attempt it. I have to create 3 screens
    : I have to create a Menu Screen
    : Add Question Screen (this will be attached to a MS access database and write to the database)
    : Take Test Screen ( this will read the ms access database to present questions to the user)
    :
    : my problem is, Do i create a seperate class for each screen and extend JFrame for each class.
    :
    : so i'd have
    :
    : public class Menu extends JFrame{}
    : class AddQues extends JFrame {}
    : class Test extends JFrame {}
    :
    : Or do i just use one screen and write over it each time i change screen.
    :
    : Thanks for your help.
    :

    What do you mean by "screen"?
    If you need 3 different "views" in your application (window) maybe you could use a CardLayout layout?
Sign In or Register to comment.