Write a Java program with a GUI

Assignment Help JAVA Programming
Reference no: EM133121974

COIT20256 Data Structures and Algorithms - Central Queensland University

Workshop Activity

Create an application to store the contact details. A Contact should contain first name, last name, email, and phone number (others can be added). The first names of Contacts should be displayed in a listview. When the user selects a name from the listview, the contact details should be displayed in a grid of TextFields or a Table. As the information is modified (a Contact's Data is updated, a new Contact is added or an existing Contact is deleted), the contacts listview should display the updated list of names.

Note: You use the solution available for Week 4 Tutorial Question Five.

Include exception handling for TextFields for entering first name, last name and phone number so that names will not contain any numbers, phone number should not contain any alphabets.

Wrtie a Java program to save the contacts created to binary file named phone.dat using ObjectOutPutStream and read and display the data from the file.

1. If no exceptions are thrown in a try block, where does control proceed to, when the try block completes execution?

2. Write a program that demonstrates how various exceptions are caught with catch (Exception exception) Define classes ExceptionA (which inherits from class Exception) and ExceptionB (which inherits from class ExceptionA). In your program, create try blocks that throw exceptions of types ExceptionA, ExceptionB, NullPointerException and IOException. All exceptions should be caught with catch blocks specifying type Exception.

3. Write a Java program with a GUI. The program reads data from an existing data file named staffphone.csv and displays all data on the text area properly after the button "Display" is pressed. The data in the file staffphone.csv have the following format
John Pearson, 49308877
Peter London, 49446701
Amy Andersen, 45009923
In addition, the program also displays total number of the phone entry on the text area.

Attachment:- Data Structures and Algorithms.rar

Reference no: EM133121974

Questions Cloud

Problems with the irr method : Acme Oscillators is considering an investment project that has the following rather unusual cash flow pattern.
How many cups of coffee the van sold last month : A mobile coffee van charges $1.80 for a cup of coffee, Last month, the sales revenue of the coffee van was E9.000 and the total variable costs were E4,000. Calc
Failure of financial institutions and financial crises : "Caribbean financial institutions are weak and poorly regulated when compared to North American financial institutions. Additionally, because the financial mark
Present value of acme future cash flows : Acme Medical Corp. is expecting the cash flows from 2018-2022 in the table below. After 2022 it is expecting growth in cash flow at an annual rate of 3%.
Write a Java program with a GUI : Write a program that demonstrates how various exceptions are caught with catch - Define classes ExceptionA and ExceptionB - In your program, create try blocks
Explain the market risk premium : You are trying to value WOW share today (End of 2021). Assume the current price of the share in the stock market is $39.06. Assume that the total dividend paid
Find lowest possible ratings : Just before the collapse of of the subprime mortgage market in 2007, the most important credit-rating agencies rated mortgage-backed securities with Aaa and AAA
How much is the total final and capital gains tax for year : Gain on sale of shares of stock subject to CGT 100,000. How much is the total final and capital gains tax for year 2018
What is the capital gains tax on the sale : Kaye sold his residential house and lot located in Manila on January 5, 2018 for 8,000,000. What is the capital gains tax on the sale

Reviews

Write a Review

JAVA Programming Questions & Answers

  Sorted values of the given array using lambdas

Sorted values of the given array using Lambdas and streams and Display the String names in ascending order after filtering the values starting with g or less.

  Write a program in java that uses a method called quadrant

JAVA) write a program IN JAVA that uses a method called quadrant that accepts as parameters a pair of double values representing an (x, y) point and returns the quadrant number for that point. Recall that quadrants are numbered as integers from 1 to ..

  A statement telling the user if they get a discount or not

The program asks the user if they have pre-registered for a conference. If the user has pre-registered, the program should call a method named discount () that displays the message "You are pre-registered and qualify for a 10% discount.

  Design and implement a program that uses nested for loops

Design and implement a program (name it Shape) that uses nested for loops to printout the shape shown below. Document your code

  Develop a multithreaded client-server application

Develop a multithreaded client/server application. The client will send a MyString to the server - statements showing the progress of the transaction on both

  Java program that will add the corresponding elements

Develop a Java program that will add the corresponding elements of two 1-dimensional arrays X and Y to produce the 1-dimensional array Z. Arrays X, Y, Z have the same dimension [M].

  Identify the constructor in the firstclassoops class

To use a class, call the constructor. Below are two Java classes. The name of the first isFirstClassOOPS. It defines variables, constructors, and methods. Identify the Constructor in the FirstClassOOPS class.

  For the given scenario identify various classes

Scenario: Universal Bank offers various services to its customers. The bank has various branches all over the country and, therefore, each branch has a unique code. For the given scenario, you have to identify various classes and their attributes

  Radio buttons and checkboxes

How are they similar and how are they different - Radio buttons and checkboxes - two types of GUI components might be useful

  Create a class rectangle with attributes length and width

Create a class Rectangle with attributes length and width, each of which defaults to 1. Provide member function that calculate and the area of the rectangle.

  Attractive design and adequate content

One way to review a presentation and assess whether slides have an attractive design and adequate content is to switch back and forth between Slide Sorter view and Normal view.

  Java :a user-defined starting position (other than 0,0)

modifying the program so that it can start from a user-defined starting position (other than 0,0) and search for a user defined ending point (other than row-1, column-1) .

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