private static int i; //iterates every time to keep track of which person in list public CalculationDisplay() { InitializeComponent(); //PROBLEM IS I CANT READ THE LIST FROM LISTPERSON CLASS solved 2/21/2017 10:57PM called ListPerson static // solved!!!! myList = CreatePersonList.GetList(); i = myList.Count() - 1; myList[i].setAdjustedGrossIn(); // does the first calculation to get the ball rolling on the others amountWithHeld = myList[i].getFedWithHold(); // direct from w2 calculatedTax = myList[i].getTaxBracket(myList[i].getAdjustedGrossIn()); //FIND A NEATER WAY OR LEAVE IT **IT WORKS** owedToFed = myList[i].taxesOwed(myList[i].getAdjustedGrossIn(), calculatedTax); refund = myList[i].taxRefund(myList[i].getAdjustedGrossIn(), calculatedTax); penalty = myList[i].penaltyBox(owedToFed, amountWithHeld); setForm2(); }
public TaxInfo3() { InitializeComponent(); CreatePersonList.sortItOut(); addTolistView(); }