\'this line calculates the subtotal before taxes and shipping sngSubTotal = sngQ
ID: 3601817 • Letter: #
Question
'this line calculates the subtotal before taxes and shipping
sngSubTotal = sngQuantity * msngQuiltCost
'this line calculates the sales tax based on the tax rate constant
sngSalesTax = sngSubTotal * CSngSalesTax
'this line caluclates the total for the order
sngTotal = sngSubTotal + sngSalesTax + msngShipping
msngSubTotal += sngSubTotal
msngTotal += msngTotal
' This line will update the counter and the accumulators
mintNumberOfSalesForToday += 1
msngTodaysGrandTotal += FormatCurrency(sngTotal)
'This is the output section
lblSubTotal.Text = FormatCurrency(sngSubTotal)
lblSalesTax.Text = FormatCurrency(sngSalesTax)
lblShipping.Text = FormatCurrency(sngShipping)
lblTotal.Text = FormatCurrency(sngTotal)
'This line is the output in the items this order box
'
lblSubTotal2.Text = FormatCurrency(sngSubTotal)
lblTaxRate2.Text = FormatCurrency(sngSalesTax)
lblShipping2.Text = FormatCurrency(sngShipping)
lblOrderTotal2.Text = FormatCurrency(sngTotal)
' This line puts the quilt information in the items this order box
lblItemsThisOrder.Text &= Chr(13) & sngQuantity & mstrItemName & msngColorName & FormatCurrency(sngSubTotal)
lblSubTotal.Text = FormatCurrency(msngSubTotal)
'This is the calculated sales total
lblSubTotal2.Text = FormatCurrency(msngSubTotal)
lblTaxRate2.Text = FormatCurrency(sngSalesTax)
lblShipping2.Text = FormatCurrency(msngShipping)
lblOrderTotal2.Text = FormatCurrency(sngTotal)
lblNumberOfSalesToday.Text = mintNumberOfSalesForToday
lblTodaysGrandTotal.Text = FormatCurrency(msngTodaysGrandTotal)
lblShipping.Text = FormatCurrency(msngShipping)
'These lines will clear and be ready for the next order
RadBaby.Checked = True
RadBaby.Checked = False
radYellow.Checked = True
radYellow.Checked = False
txtQuantity.Text = ""
txtPrice.Text = ""
txtColor.Text = ""
'This will put the cursor back in the quantity text box
txtQuantity.Focus()
Quilts Quilt's O Baby Quit-$20.00 Items This Order Margaret's Quilts Lap Quilt-$30.00 O Twin Quilt-s35.00 O Full Quit-$40.00 O Queen Quilt-$50.00 Kng Quilt-$75.00 Quantity Quilt Price Color Sub Total Sales Tax Color O Yellow Shipping Blue Total Peach Sub Total Sales Tax Shipping Order Total Shipping Free Standered 3-7 Days-$5.95 O Two-Day-$12.00 O Next Day-$25.00 Next Item 0 Number Of Sales Today Clear Clear All Exit Todays GrandTotalExplanation / Answer
mintNumberOfSalesForToday += 1
msngTodaysGrandTotal += FormatCurrency(sngTotal)
'This is the output section
lblSubTotal.Text = FormatCurrency(sngSubTotal)
lblSalesTax.Text = FormatCurrency(sngSalesTax)
lblShipping.Text = FormatCurrency(sngShipping)
lblTotal.Text = FormatCurrency(sngTotal)
'This line is the output in the items this order box
'
lblSubTotal2.Text = FormatCurrency(sngSubTotal)
lblTaxRate2.Text = FormatCurrency(sngSalesTax)
lblShipping2.Text = FormatCurrency(sngShipping)
lblOrderTotal2.Text = FormatCurrency(sngTotal)
' This line puts the quilt information in the items this order box
lblItemsThisOrder.Text &= Chr(13) & sngQuantity & mstrItemName & msngColorName & FormatCurrency(sngSubTotal)
lblSubTotal.Text = FormatCurrency(msngSubTotal)
'This is the calculated sales total
lblSubTotal2.Text = FormatCurrency(msngSubTotal)
lblTaxRate2.Text = FormatCurrency(sngSalesTax)
lblShipping2.Text = FormatCurrency(msngShipping)
lblOrderTotal2.Text = FormatCurrency(sngTotal)
lblNumberOfSalesToday.Text = mintNumberOfSalesForToday
lblTodaysGrandTotal.Text = FormatCurrency(msngTodaysGrandTotal)
lblShipping.Text = FormatCurrency(msngShipping)
'These lines will clear and be ready for the next order
RadBaby.Checked = True
RadBaby.Checked = False
radYellow.Checked = True
radYellow.Checked = False
txtQuantity.Text = ""
txtPrice.Text = ""
txtColor.Text = ""
'This will put the cursor back in the quantity text box
txtQuantity.Focus()
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.