Menu

[Solved]Create Gui Application Named Propertytaxjava Displays Assessed Value Property Tax User Ent Q37170928

Create a GUI application named PropertyTax.java that displaysthe assessed value and property tax when a user enters the actualvalue of a property.

Example calculation of the annual property tax owed on aproperty worth $100,000

Y2gluJ3IVbBvfwP4VOUDsNLmVNAAAAAElFTkSuQm

Note the distinction between appraised value and assessedvalue.

  • The appraised value is somewhat comparable to market valuei.e. how much the property is worth or how much someone is likelyto pay for it.
  • The assessed value is a portion of the appraised value andis the value used when calculating property tax. In FairfieldCounty the assessed value is always 35% of the appraisedvalue.

Code below needs to be edited so it asks the user for thevalue of the property, then gives the above results screen

import javax.swing.*;
import java.awt.*;

public class PropertyTax
{

public static void main(String[] args)
{
final JFrame frame = new JFrame(“JTable Demo”);

String[] columns = {“Name”, “Value”, “Total”};  
double appraisedVal = 10000;
double assessedVal = appraisedVal*0.35;
double taxM = 42.28;
double taxF = (taxM/1000);
double tax = assessedVal*taxF;
Object[][] data =
{
{“Appraised Value”, “=”+appraisedVal, appraisedVal},
{“Assessed Value”, “=”+appraisedVal+”*0.35”, assessedVal},
{“Tax Rate (Mil)”, “=”+taxM, “”},
{“Tax Rate (factor)”,”=”+taxM+”*(1/1000)”,taxF},
{“Tax Owed”, assessedVal+”*”+taxF,tax
}
};

    JTable table = new JTable(data,columns);
JScrollPane scrollPane = new JScrollPane(table);
table.setFillsViewportHeight(true);

JLabel lblHeading = new JLabel(“My Table”);  

frame.getContentPane().setLayout(newBorderLayout());

frame.getContentPane().add(lblHeading,BorderLayout.PAGE_START);  
frame.getContentPane().add(scrollPane,BorderLayout.CENTER);  

frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);  
frame.setSize(650, 300);   
frame.setVisible(true);   
}
}

Expert Answer


Answer to Create a GUI application named PropertyTax.java that displays the assessed value and property tax when a user enters the… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *