Question
Discussion 1:
Compare Swing Java GUI components to AWT components. Explain at least one way the components are similar and at least one way they are different. Provide examples to support your rationale.

Discussion 2:
Create a GUI application with JFrame that contains five labels describing reasons that a customer might not buy a specific product (e.g. “too expensive”). Place a JButton on the JFrame, and code its functionality so that every time the user clicks on the button one of the reasons is removed from a label.
You need to submit original .java files as an attachment to your initial response. (Please do not copy/paste the whole file code into your response.) Zip them into a single .zip file and attach the .zip file to your post. In the initial response itself, please provide comments and explanations of your solution.
Solution Preview

These solutions may offer step-by-step problem-solving explanations or good writing examples that include modern styles of formatting and construction of bibliographies out of text citations and references.
Students may use these solutions for personal skill-building and practice.
Unethical use is strictly forbidden.

public class Discussion1 extends JFrame implements ActionListener{

    private Button awt;
    private JButton swing;
    private JLabel output;
    private Container con;
   
    public Discussion1() {
       super("Dicussion 1");
       setSize(100,150);; // windows size
       setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); // closed operation
       setLayout(new FlowLayout());
       swing = new JButton("Swing button");
       awt = new Button("AWT button ");
       output = new JLabel();
       // add(swing);
       add(awt);
       add(swing);   
       add(output);
       awt.addActionListener(this);
       swing.addActionListener(this);
      
    }
This is only a preview of the solution.
Please use the purchase button to see the entire solution.
By purchasing this solution you'll be able to access the following files:
Solution.zip
Purchase Solution
$40.00
Google Pay
Amazon
Paypal
Mastercard
Visacard
Discover
Amex
View Available Computer Science Tutors 639 tutors matched
Ionut
(ionut)
Master of Computer Science
Hi! MSc Applied Informatics & Computer Science Engineer. Practical experience in many CS & IT branches.Research work & homework
5/5 (6,804+ sessions)
1 hour avg response
$15-$50 hourly rate
Pranay
(math1983)
Doctor of Philosophy (PhD)
Ph.D. in mathematics and working as an Assistant Professor in University. I can provide help in mathematics, statistics and allied areas.
4.6/5 (6,670+ sessions)
1 hour avg response
$40-$50 hourly rate
Leo
(Leo)
Doctor of Philosophy (PhD)
Hi! I have been a professor in New York and taught in a math department and in an applied math department.
4.9/5 (6,425+ sessions)
2 hours avg response

Similar Homework Solutions