Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

<p>Suppose automobile repair customers are billed at the rate of $35 per hour fo

ID: 3622783 • Letter: #

Question

<p>Suppose automobile repair customers are billed at the rate of $35 per hour for labor. Also costs for parts and supplies are subject to a 5% sales tax. Write a program to display a simplified bill. The customers name, the number of hours of labor, and the cost of parts and supplies should be entered into the program via text boxes. When a button is clicked, the customers name(indented) and the three costs should be displayed in a list box, as shown in chapter three page 118 figure 3.19 of the text book.</p>
<p>&#160;</p>

Explanation / Answer

Private Sub Command1_Click() Dim labr, prts, taxs, tot1 As Single Dim labrT, prtsT, taxsT, tot1T As String If Text2 = "" Then Text2 = 0 If Text3 = "" Then Text3 = 0 List1.Clear labr = Round((35 * Val(Text2)), 2) prts = Round(Val(Text3), 2) taxs = Round((prts * 0.05), 2) totl = Round((labr + prts + taxs), 2) labrT = Right(" " & Format(labr, "$#,##0.00"), 10) prtsT = Right(" " & Format(prts, "$#,##0.00"), 10) taxsT = Right(" " & Format(taxs, "$#,##0.00"), 10) totlT = Right(" " & Format(totl, "$#,##0.00"), 10) List1.AddItem "BILL" List1.AddItem "________" List1.AddItem "" List1.AddItem "Customer's Name: " & Text1 List1.AddItem "" List1.AddItem "Labor Cost" & " $35 x " & Text2 & vbTab & vbTab & labrT List1.AddItem "Parts and Supplies Cost " & vbTab & vbTab & prtsT List1.AddItem "Sales Tax" & vbTab & vbTab & vbTab & vtab & taxsT List1.AddItem " " & vbTab & vbTab & vbTab & vbTab & "__________" List1.AddItem "Total Bill" & vbTab & vbTab & vbTab & vbTab & totlT End Sub Private Sub Command2_Click() Unload Me End Sub

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote