Hello. I'm having trouble with a program that I have to write for my computer concepts class that's due next month, when we actually cover VB. I'm not asking anyone to do my homework for me, since I've got everything I need done. The program does what it's supposed to do, but I can't figure out how to make the currency display in the textbox with only 2 numbers after the decimal instead of 4. Anyone have a good idea on how to do this?
Here's what I have which is working fine:
Thanks in advance.Code:Private Sub cmdCalculate_Click()
Dim cBillAmt@, cTipAmt@
Dim sPercent!
cBillAmt@ = CCur(txtAmount.Text)
sPercent! = CSng(txtPercentage.Text)
cTipAmt@ = cBillAmt@ * sPercent!
txtTipAmt.Text = "$" & CStr(cTipAmt@)
End Sub
-Daft
