What is wrong with my listbox?

Hi I have a ListBox with only one column, and it incorporates a popup menu. The Links below show the normal view and the popup view.

link text

link text

It works fine if I click on either 2013 or 2014 and then click on any of the menu items. However, if I click on either of the years, and then click anywhere else in the listbox it is as if I have selected year 2014 and month May.

Here is my code for the Listbox MouseDown:

If Me.ColumnFromXY(x, y) = 0 Then Return True End If

And here is the code for the MouseUp:

[code]Dim g As Graphics
Dim Left As Integer
Dim Top As Double
// Display menu if clicked in PopupMenu column
Dim i, k, year As Integer
Dim month, m As String
Dim row As Integer = Me.RowFromXY(x, y)
Dim col As Integer = Me.ColumnFromXY(x, y)
fromDatabase = True
Me.ListIndex = row
Me.Selected(row) = True

Dim rt As Integer
Dim d As New Date
Dim d2 As Boolean
Try
rt = Me.RowTag(Me.ListIndex)
Catch err As OutOfBoundsException
MsgBox(“Please just click the pointer!”)
Exit
End Try
getMonths(rt)
Dim base As New MenuItem
If Me.RowTag(Me.ListIndex) = rt Then
For i = 0 to UBound(selectedMonthNames)
base.Append(New MenuItem(selectedMonthNames(i)))
Next
End If

Dim selectedMenu As MenuItem
selectedMenu = base.PopUp

If selectedMenu <> Nil Then
// CellTextPaint will check for a value in the CellTag
// and display it.
Me.CellTag(row, col) = selectedMenu.Text

year = rt + App.startYear
month = selectedMenu.Text

Select Case month
Case "January"
  m = "01"
Case "February"
  m = "02"
Case "March"
  m = "03"
Case "April"
  m = "04"
Case "May"
  m = "05"
Case "June"
  m = "06"
Case "July"
  m = "07"
Case "August"
  m = "08"
Case "September"
  m = "09"
Case "October"
  m = "10"
Case "November"
  m = "11"
Case "December"
  m = "12"
End Select
d.Day = 1
d.Month = Val(m)
d.Year = year

End If
RainGauge.setupDays(d)
fromDatabase = True
RainGauge.getData(d)
k = UBound(daysAmount)
For i = 0 to k
Top = 590 - (daysAmount(i) * 4)
Top = Top + 20
day(i).DrawInto(g, Left, Top, Str(daysAmount(i)))
Me.Invalidate(False)
Next[/code]

I am fairly sure this code is OK, as I really studied the ListBox Webinar that has been released lately.