#1
|
||
|
Visual Basic Help
i need help to change everything, this is just a template how to work a calculator of some sort can anybody help me?
Design Specification: A local motorcycle business, Choppers Inc., has had a revival over recent years with many baby boomers deciding that they want to get back on bikes and enjoy life. This fact has changed the way that Choppers Inc does business. They used to be a very small backyard business that did custom modifications on older bikes. Essentially the owners of Choppers Inc. knew the bikers who required the modifications to their bikes. Everything including quotes and payments were done by word of mouth and it all worked well. However, the business cannot cope with this way of operating anymore. Bucket, the owner of Choppers Inc., has asked you at IT Kids to come up with a business solution for them. This solution will include quotes, stock control, paying employees, and invoicing. This is a big project. However, even though Bucket knows you through one of his employees, Spanner, he needs to be sure you can produce a solution that will meet his needs. To this end Choppers Inc. has asked you to produce the payroll module for their business. The payroll needs to have the following features: Data entry of the employee’s name and the hours they worked for that week. If you choose to do so, you can also enter the pay rate for that employee. The name could be selected from a list, if you choose to do so. There is no overtime. If they type in their name, then an existence check must be performed to ensure that something is entered. The hours worked must also be type checked to insure that only numbers can be entered. The program will use the input data to: · Calculate the gross weekly wage of the employee using the employee pay rates given. · Deduct the 8% superannuation amount from the gross weekly wage · Calculate the weekly tax paid on the remainder using the data in the supplied tax table · Calculate the net weekly wage. · Display the employees name, weekly hours worked, hourly pay rate, weekly gross pay, weekly superannuation deduction, weekly tax deduction and weekly net wage. · Be able to calculate the wages of all 5 employees, one after the other, i.e., you do not have to restart the program each time you calculate a person’s pay. Taxable Income
Tax Payable $0 – $6,000 Nil $6,000.01 – $20,000 17c for each $1 over $6,000 $20,000.01 - $50,000 $2,380 plus 30c for each $1 over $20,000 $50,000.01 – $60,000 $11,380 plus 42c for each $1 over $50,000 Over $60,000 $15,580 plus 47c for each $1 over $60,000 Superannuation is calculated at 8% of gross for each employee. That is, all employees have asked that 8% of their pay be deducted from their gross salary as part of their pay package. Employee data Max Driver (apprentice) $18 per hour James Wheel-Cover $25 per hour Spanner Turner $27.50 per hour Anne Tyre $25 per hour Lyle Scooter (apprentice) $18 per hour Programming Task From the design specification you are required to complete the following tasks:
Description Format Data Type
=----------------------------------------------------------------------------------- here is my start but needs to be changed.... Option Explicit Dim employee As String Dim hw As Integer Dim npay As Currency Dim grosspay As Currency Dim TI As Currency Dim super As Currency Dim tax As Currency Dim NetPay As Currency Dim payrate As Currency Private Sub Calculate_Click() calculategrosspay calculateSuper calculateTax calculateTI NetPay = (TI - tax) / 52 txtnpay.Text = Format(Val(NetPay), "currency") End Sub Public Sub calculateTax() If TI * 52 <= 6000 Then tax = 0 Else If TI * 52 <= 20000 Then tax = (((TI) * 52 - 6000) * 0.17) / 52 Else If TI * 52 <= 50000 Then tax = 2380 + (((TI) * 52 - 20000) * 0.3) / 52 Else If TI * 52 <= 60000 Then tax = 11380 + (((TI) * 52 - 50000) * 0.42) / 52 Else tax = 15580 + (((TI) * 52 - 60000) * 0.47) / 52 End If End If End If End If txttax.Text = Format(tax, "currency") End Sub Private Sub END_Click() End End Sub Private Sub New_Click() txtemployee.Text = "" txthw.Text = "" txtNetPay.Text = "" txtPR.Text = "" txtsuper.Text = "" txttax.Text = "" txtGP.Text = "" txtemployee.SetFocus End Sub Public Sub calculateGP() GP = Val(payrate.Text) * Val(hw.Text) txtGP.Text = Format(GP, "currency") End Sub Public Sub calculateTI() TI = (GP - super) * 52 End Sub Public Sub calculateSuper() super = GP * 0.08 txtsuper.Text = Format(super, "currency") End Sub Private Sub Print_Click() hw = txthw.Text Printer.FontName = "times new roman" Printer.FontSize = "12" Printer.Print "", "Choppers Inc. Payroll" Printer.Print Printer.Print "", "Employee Payslip", "", Date Printer.Print Printer.Print "", employee; Name Printer.Print Printer.Print "Hours", "Pay", "Superannuation", "Tax", "NetPay" Printer.Print Printer.Print hw, Format(Val(NPR), "currency"), Format(Val(super), "currency"), Format(Val(tax), "currency"), "", "", Format(Val(NetPay), "currency") Printer.EndDoc End Sub Private Sub txtNetPay_Change() txtNetPay = GP - tax - super End Sub |
#2
|
||
|
wtf is that ?
and on a side note wow this forum has gone quite. |
#3
|
||
|
Im not going to help you do your homework
|
Thread Tools | Search this Thread |
Display Modes | |
|
|