![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Oct 2006
Posts: 19
Rep Power: 0
![]() |
Format Exception Error
Hi, I have a format exception error when I try and calculate the price of a product and service in a program using menu bars in vb. I'm not sure what's wrong except there's an error with index(zero-based) not being the correct size. Here's the small portion of the code (the error is in a portions like this.)
If rad2.Checked = True Then
If radF.Checked = True Then
total = 12.0
'add deposit and display
Deposit = 30.0
total = total + Deposit
total = FormatCurrency(total, 2)
lstOutput.Items.Add(String.Format(fmtTable, "Lawn mower ", FormatCurrency(12.0, 2), "(Full-day rental)"))
lstOutput.Items.Add(String.Format(fmtTable, "Deposit", FormatCurrency(Deposit, 2)))
lstOutput.Items.Add("----------------")
lstOutput.Items.Add(String.Format(fmtTable, "Total", FormatCurrency(total, 2)))
End IfJust please tell me what to do to correct it, I only know up to menubars and select case, it's for my comp. science class. Thanks. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| C# corruption!!! | Kilo | C++ | 32 | May 21st, 2006 8:44 PM |
| Masm | rsnd | Assembly | 4 | May 20th, 2006 9:05 PM |
| Could some please explain classes to me... | TCStyle | C++ | 10 | Feb 20th, 2006 3:51 PM |
| libraries | matko | C | 1 | Jan 22nd, 2006 2:12 PM |
| HELP please!!! | hamacacolgante | C | 7 | Nov 21st, 2005 5:36 AM |