Bubble sort is not working
<p>Currently the user is able to input numbers into the ListBox, and I want the ListBox to be sorted by the bubble sort below when a sort checkbutton is clicked. However, it only outputs the index number e.g. 0,1,2,3... I am not allowed to use any array or containers just the items property and parsing and converting. </p>

<pre><code>private void sorted()
{
    int a = Convert.ToInt32(lstHoldValue.Items.Count);
    int temp;
    for (int i = 0; i &lt; a; i++)
    {
        for (int j = i + 1; j &lt; a; j++)
        {
            if (Convert.ToInt32(lstHoldValue.Items[i]) &gt;
                Convert.ToInt32(lstHoldValue.Items[j]))
            {
                temp = Convert.ToInt32(lstHoldValue.Items[i]);
                (lstHoldValue.Items[i]) = Convert.ToInt32(lstHoldValue.Items[j]);
                (lstHoldValue.Items[j]) = temp;
            }
        }
    }

    lstHoldValue.Items.Clear();
    for (int i = 0; i &lt; a; i++)
    {
        Convert.ToInt32(lstHoldValue.Items.Add("\t" + i));
    }
}
</code></pre>