Vb 2005 looping listbox

Hi all i need help on listbox.

The itemlistbox fill with 3 item and the price of the three item will be on the array

when select the itemlistbox item and click add, it will update on an orderlistbox and it will also retrieve the price from the array and add to total amount.

since u can add, there is also a delete item. I hav done the code on delete the item on the orderlistbox but the problem is to minu the deleted item price at totalprice

i try to use a if statement n inside i create a for loop to loop inside itemlistbox to get the index of the array to retrieve the price, but the looping dun seem to work on listbox -_-

is there any way to solve it? or is it possible to assign a value on the item inside the listbox?

thanks for reading.

Dim intCount As Integer = 0
Dim listCount As Integer = itemListbox.Items.Count - 1
If (purchaseListbox.SelectedIndex) Then
For intCount = 0 To listCount
If purchaseListbox.SelectedItem = itemListbox.Items(intCount) Then
totalAmount -= itemPrice(intCount)
End If

        Next
    End If