Prepare a java application will read the database file

Assignment Help JAVA Programming
Reference no: EM13892894

The application shall work as follows:

714_GUI_for_Application.png

1. Upon start-up, the application will read the database file. The path of the database file will be supplied by a run-time parameter. If the database file does not exist, the user will be told the database does not exist and prompted (non-GUI text prompt) asking if they want to create a new one. If the user answers positive, the application will continue with an initially empty song database. If the user answers negatively, the application will exit. An example of an appropriate start-up command is as follows: java SongDB mySongDB.data

2. The original state of the frame shall display the combo box with the first song in the database selected. The Item Code, Description, Artist, Album, and Price fields for this item shall be displayed with the fields disabled (non-editable). The Add, Edit, Delete, and Exit buttons shall be enabled, and the Accept and Cancel buttons shall be disabled.

3. To add a song, the user clicks on the Add button. This will cause the application to clear and enable the Item Code, Description, Artist, Album, and Price fields so the user can enter information for the new song. The Edit and Delete buttons are also disabled, and the Accept and Cancel buttons are enabled. When the user presses the Accept button, the new song will be added to the database and combo box. If the user presses the Cancel button, the entry transaction is canceled and the frame reverts to its original state.

4. To edit an existing song, the user shall select the song from the combo box. The information for the selected song shall then be displayed in the disabled fields. The user then presses the Edit button, which enables the Description, Artist, and Price fields. The user may not change the Item Code.

The Add, Edit, and Delete buttons are disabled, and the Accept and Cancel buttons are enabled. If the user presses the Accept button, the changes are saved and the combo box is updated. If the user presses the Cancel button, the edit transaction is canceled and the frame reverts to its original state.

5. To delete an existing song, the user shall select the song from the combo box. The information forthe song shall then be displayed in the disabled fields. If the user presses the Delete button, the song is deleted from the database and the combo box.

6. When the user presses the Exit button the application shall terminate. The current state of the database shall be saved in a file using the pathname supplied at program start-up (see above).

7. Data fields shall be validated to ensure they are not blank with appropriate error messages displayed. If the song is a single, the text "None" will be used for the album name. The price field shall be validated to ensure only numeric data is entered.

Reference no: EM13892894

Questions Cloud

What could be your picot statement : Based on the above, what will be the impact of the problem, and what can you say is the proposed solution from the PICOT statement?
Prepare closing journal entries : 1.Use the May 31 fiscal year end information from the following ledger accounts (assume that all accounts have normal balances) to prepare closing journal entries and then post those entries to the appropriate ledgeraccounts
Facebook social-context : Nike bought ads on users' homepages in 20 countries prior to the World Cup, and Ford uses Facebook's social-context ads to promote the Explorer. Although most ads on Facebook cost as little as a dollar per click to marketers, the total cost of a s..
Why is a nursing taxonomy important : What is the advantage of having a unified language for nursing within the larger concept of a unified language system for the healthcare community?
Prepare a java application will read the database file : Prepare a java application will read the database file. The path of the database file will be supplied by a run-time parameter. If the database file does not exist, the user will be told the database does not exist.
How many hospitality majors enter the work : How many hospitality majors enter the work force after graduation?
Explore how it is dealt with in three different greek myths : For your final paper, CHOOSE ONE OF THE FOLLOWING THEMES (or choose one of your own) and explore how it is dealt with in THREE different Greek myths: Memory and forgetting, Home (what is it? Why is it important?) and Religious reverence and the pow..
A hotel outside the united states : What are the benefits of working for a hotel outside the United States?
Factors that affecting companys ability to break even : Identify three factors that are affecting airline company's ability to break even. For each of your factors, discuss how these have an impact on the breakeven (contribution margin, fixed costs, variable costs, a combination, etc.), and what happen..

Reviews

Write a Review

 

JAVA Programming Questions & Answers

  Start developing java code to ask questions

You are ready to start developing Java code to ask questions on customer information and the sub that customers want to order. You are only concerned with the functionality to request and provide feedback on what the customer entered

  Java program which handles events from different sources

how to setup a program to respond to events from any one of these sources. How do you create the necessary listener class? How do you associate the listener object with the event source?

  How to detect the correct ip address and run it locally

When you compile the two modules, with disabling the package statement, it runs on one single machine, that's running the server

  How threads are used to implement currency in java

Describe the concept of concurrency and how threads are used to implement currency in Java

  Ask the user how many times you want to run

c the algorithm. 2. Then choose a word at random from the array of Strings as the target (Use the integer random number generator)

  Concept of time in javascript

In JavaScript a time is dened as a Date Object. Each date object stores its state as a time value,which is a primitive number that encodes a date.

  Implementing a relatively simple text-compression scheme

You will be implementing a relatively simple text-compression scheme - It should run from the command line.

  Write a dim statement that declares a myfriend variable

Write a Dim statement that declares a MyFriend variable named school. Write an assignment statement that  assigns the value in the txtFirst control to the strFirst member

  Exception handling

Write a java program to Facilitates keyboard input by abstracting details about input parsing, conversions, and exception handling.

  Assignment on java programming

The listing of Tree.java is supplied below as a starting point for this lab. A picture of Tree.java output is also shown. Either cut/paste the code or type it in. Run the program to verify that it works. Study the listing until you understand comp..

  Write program that uses a class named rectangle

Write program that uses a class named Rectangle. The class has floating point attributes length and width. it has member functions that calculate the perimeter and area of the rectangle. It also has set and get functions for both length and width.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd