• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

i need help with assignment please am new student.

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Create an Airline reservation program with fields for:
first name and last name, address, city, state and zip
flight number
date and time of flight
starting city and ending city
credit card number and type of card (MasterCard, Visa or Discover)
Use labels and textfields for name, address, city, state and zip
Use a label and combo box to select a list of flight numbers (include at least 5 flight numbers)
Use a label and list for a list of dates (include at least 5 dates)
Use a label and slider to select at least 5 different flight times
There should be at least 3 buttons on form
a submit button - when the user clicks submit, a new window should pop up using a text area to display all information in a nicely formated form.
a clear button - use to clear all textfields and reset default values
an exit button - to close the program
The informational frame uses a text area to display all information and contains a close button to exit the frame and return to the main window when user is done viewing information.
The main class, Asg10
creates the ReservationFrame (or whatever you called your main frame class)
sets the title for the frame
sets the location of the frame
assigns a default close operation
sets visible to true


I suggest using one panel for textfields, another panel for combo box, list and slider, and a final panel for the three buttons. You will need to select the the best layout for each panel to make objects display as you like. Add those to the main frame using more than likely a BorderLayout.

Suggestion: You can use more panels to improve layout and place panels within other panels before adding to main frame. For example, if you have six JTextFields for first name, last name, address, city, state and zip, you could use three panels all with FlowLayout set to left. Add the first name label, first name textfield, last name label and last name textfield to the first FlowLayout panel, the address label and address textfield to the second FlowLayout panel, and add the labels and textfields for city state and zip to the third FlowLayout panel. Then, add all three panels to a grid layout panel using 3 rows and 1 column. So be creative, the sky is the limit.
 
Sheriff
Posts: 67752
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You forgot to post your code and the specific problems that you are having with it.
 
Rancher
Posts: 387
30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The assignment looks like a description for writing a Swing App.

You posted in the JavaFX section.
I'd advise writing a JavaFX application as it is a newer system and I think is superior for this kind of app.
By writing a JavaFX application, I think you will acquire useful and relevant skills.

To learn how to create a JavaFX application, follow the documentation below, compiling and running the example programs at each step:

  • Follow the makery.edu JavaFX tutorials
  • Work through Getting Started with JavaFX Scene Builder 1.0
  • Work your way through the JavaFX documentation Layouts and UI Controls sections
  • write small example programs and trying out anything else that you need to learn to teach yourself how to create your program


  • You'll probably also need to make sure that you understand any basics of the Java programming language that you currently don't know:

  • The JavaFX Tutorial Trails covering (just) the basics of Java Development


  • The above tutorials and documentation will include information on how to setup your development platform and create basic applications in JavaFX.

    Once you understand the basics, try writing your assignment program.

    Steps to writing your program are:

  • Setup your development environment
  • Create the basic layout in SceneBuilder
  • Have Scene Builder create a skeleton app for you
  • Open the skeleton app in your IDE (e.g. NetBeans or Eclipse)
  • Make sure the skeleton app runs
  • Incrementally add logic to support your UI, compiling, running and testing your program after each incremental change
  • Once all the basic functionality is working correctly, make your app look nice by using nice fonts, images and color palettes by applying css styles


  • Do all that yourself and do it well and you will learn a lot and get an A.
    All information required to do this is in the links I have provided in this post.

    ---------

    Before posting more, I advise reading and following the advice under what have you tried.

     
    What are you saying? I thought you said that Santa gave you that. And this tiny ad:
    Gift giving made easy with the permaculture playing cards
    https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
    reply
      Bookmark Topic Watch Topic
    • New Topic