Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

| Question 6 (12 MARKSI Book Online is a business that sells rare books via the Internet and has the order delivered. Below is some

image text in transcribed

| Question 6 (12 MARKSI Book Online is a business that sells rare books via the Internet and has the order delivered. Below is some of the code for a GUN. Answer the questions that follows. import java.awt. Sport AVA.applet.. import java.awt.event. import java.text.Decimal Format public class Ordorpplat extends Applet implements ItonListener // Create components for Applot Label COMPyNanoLabel - now Label (Your online Bookstore) Tabel priceLabel now Label("Please enter the total amount of your order: Textield pricefield -new Textield (35) Label delivery Label new Label (Please choose your method of delivery CheckboxGroup deliveryGroup - now CheckOONGEOUP(); Checkbox One Day Box new Checkbox Priority Overnight) talno, deliveryGroup Checkbox twoDayBox - now Cheekbok(ExProSs (2 busin daya) false, deliveryGroup) Checkbox moreDayaBON - Dow Cheekbok(standard (3 to 7 business days) false, deliveryGroup); Checkbox hiddenbox - new Checkbox , true, deliveryGroup) Label outputLabel - now Label("We guarantee on time delivery. OE Toney back.) a publie vold unit 1 Add cuponents to window and set colors Set Rackground (Colox.cyan) add (company Name Label> add (pe OoLabel) add (pricerola) PricerLold. request FOCUS add (dolavoryLabel) add (oneDay Box) oneDAYBOX.adaitemlistener(this) add (twoDayBox) twoDay Box. add itemlistener(this). add (morDayaBox) moreDayaBox.add ItemLiotonar (thia); add (outputrabol), (TURN OVER] OCTOBER/NOVEMBER 2019 public void ItemstateChanged (Icement choice double dellvery double price obtain the value of price and calculate the delivery fee 11 Display output output Label.botPoregaound (Color.black) Decimal Format twoDigita-new Decanal Format ( . output Label.setText("Your total cont la twoDigita.format (price + delivery) ..00-> catch (NumberTotException e) . outputLabel.setText (Amount must be greater than 0 outputLabel.setroreground (Color.red) hiddenBox. But state (true). priceField.setText( ) Pricerreld. request Focus() 6.1 6.2 6.3 (6) What is the purpose of the statement in ? Draw the GUI that the statements in method creates. Complete the method itemStateChanged in . First obtain the value of the total amount of the order as well as the delivery method selected. Then calculate the final amount due as follows: (5) . If the delivery method is priority, then the final amount is the order amount + 20%. If the delivery method is express, then the final amount is the order amount + 10%. of the delivery method is standard, and the order amount is greater than R75.00, then the final amount is the order amount, else add 5% to the final amount. | Question 6 (12 MARKSI Book Online is a business that sells rare books via the Internet and has the order delivered. Below is some of the code for a GUN. Answer the questions that follows. import java.awt. Sport AVA.applet.. import java.awt.event. import java.text.Decimal Format public class Ordorpplat extends Applet implements ItonListener // Create components for Applot Label COMPyNanoLabel - now Label (Your online Bookstore) Tabel priceLabel now Label("Please enter the total amount of your order: Textield pricefield -new Textield (35) Label delivery Label new Label (Please choose your method of delivery CheckboxGroup deliveryGroup - now CheckOONGEOUP(); Checkbox One Day Box new Checkbox Priority Overnight) talno, deliveryGroup Checkbox twoDayBox - now Cheekbok(ExProSs (2 busin daya) false, deliveryGroup) Checkbox moreDayaBON - Dow Cheekbok(standard (3 to 7 business days) false, deliveryGroup); Checkbox hiddenbox - new Checkbox , true, deliveryGroup) Label outputLabel - now Label("We guarantee on time delivery. OE Toney back.) a publie vold unit 1 Add cuponents to window and set colors Set Rackground (Colox.cyan) add (company Name Label> add (pe OoLabel) add (pricerola) PricerLold. request FOCUS add (dolavoryLabel) add (oneDay Box) oneDAYBOX.adaitemlistener(this) add (twoDayBox) twoDay Box. add itemlistener(this). add (morDayaBox) moreDayaBox.add ItemLiotonar (thia); add (outputrabol), (TURN OVER] OCTOBER/NOVEMBER 2019 public void ItemstateChanged (Icement choice double dellvery double price obtain the value of price and calculate the delivery fee 11 Display output output Label.botPoregaound (Color.black) Decimal Format twoDigita-new Decanal Format ( . output Label.setText("Your total cont la twoDigita.format (price + delivery) ..00-> catch (NumberTotException e) . outputLabel.setText (Amount must be greater than 0 outputLabel.setroreground (Color.red) hiddenBox. But state (true). priceField.setText( ) Pricerreld. request Focus() 6.1 6.2 6.3 (6) What is the purpose of the statement in ? Draw the GUI that the statements in method creates. Complete the method itemStateChanged in . First obtain the value of the total amount of the order as well as the delivery method selected. Then calculate the final amount due as follows: (5) . If the delivery method is priority, then the final amount is the order amount + 20%. If the delivery method is express, then the final amount is the order amount + 10%. of the delivery method is standard, and the order amount is greater than R75.00, then the final amount is the order amount, else add 5% to the final amount

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database And Expert Systems Applications Dexa 2023 Workshops 34th International Conference Dexa 2023 Penang Malaysia August 28 30 2023 Proceedings

Authors: Gabriele Kotsis ,A Min Tjoa ,Ismail Khalil ,Bernhard Moser ,Atif Mashkoor ,Johannes Sametinger ,Maqbool Khan

1st Edition

303139688X, 978-3031396885

More Books

Students also viewed these Databases questions

Question

What is Working Capital ? Explain its types.

Answered: 1 week ago

Question

1. Write down two or three of your greatest strengths.

Answered: 1 week ago

Question

What roles have these individuals played in your life?

Answered: 1 week ago

Question

2. Write two or three of your greatest weaknesses.

Answered: 1 week ago