I am a novice to VB. I am creating an invoice form from a database. I have allowed for a maximum of 5 items. I have created code to calculate each item total price (Total1 = Price1*Quantity etc). These are then sutotalled, carriage added, vat calculated and grand totalled. This works well, but only if there are 5 items, any less and it will not run. I have tried setting default value of each total to 0, and I also created code
Dm Total2
If Quantity2 = "" Then
Total2 = 0
Else If Quantity = "*" Then
Total2 = Price2*Quantity2
End If
But this just will not run and I cannot understand the debugging.
Can anybody set me straight?
Dm Total2
If Quantity2 = "" Then
Total2 = 0
Else If Quantity = "*" Then
Total2 = Price2*Quantity2
End If
But this just will not run and I cannot understand the debugging.
Can anybody set me straight?