title: only one item in listbox being updated?
body: <p>Hi I have the following code to search and the searched items are displayed in the listbox. I also have an update button that updates whatever new information you input in a textbox. the update box works fine but for some reason when multiple duplicated items are displayed in the listbox and i try to click the 2nd instance and try to update, it updates the original and not the 2nd instance. So, the first instance should update first instance item, and 2nd should update 2nd but right now, 1st is updating 1st instance, 2nd is updating 1st instance, 3rd is updating 1st instance - always updating the 1st instance. how can i fix this? this is the document: <a href="https://www.dropbox.com/s/36e9fmbf17wpa0l/example.xlsm" rel="nofollow">https://www.dropbox.com/s/36e9fmbf17wpa0l/example.xlsm</a></p>
  
  <pre><code>Public Sub Search_Click()
  Dim Name As String
  Dim f As Range
  Dim s As Integer
  Dim FirstAddress As String
  Dim str() As String
  Dim ws As Worksheet
  
  Set ws = ThisWorkbook.Worksheets("Master")
  
  Name = surname.Value
  
  With ws
   Set f = .Range("A:A").Find(what:=Name, LookIn:=xlValues)
    If Not f Is Nothing Then
     With Me
      firstname.Value = f.Offset(0, 1).Value
      tod.Value = f.Offset(0, 2).Value
      program.Value = f.Offset(0, 3).Value
      email.Value = f.Offset(0, 4).Text
  
      SetCheckBoxes f.Offset(0, 5) '&lt;&lt;&lt; replaces code below
  
      officenumber.Value = f.Offset(0, 6).Text
      cellnumber.Value = f.Offset(0, 7).Text
      r = f.Row
     End With
      findnext
          FirstAddress = f.Address
  Do
      s = s + 1
      Set f = Range("A:A").findnext(f)
              Loop While Not f Is Nothing And f.Address &lt;&gt; FirstAddress
      If s &gt; 1 Then
         Select Case MsgBox("There are " &amp; s &amp; " instances of " &amp; Name, vbOKCancel Or vbExclamation Or vbDefaultButton1, "Multiple entries")
  
         Case vbOK
              findnext
         Case vbCancel
  
         End Select
  
      End If
  
  Else: MsgBox Name &amp; "Not Listed"
  
  End If
  
  End With
  
  End Sub
  
  '-----------------------------------------------------------------------------
  Sub findnext()
  Dim Name As String
  Dim f As Range
  Dim ws As Worksheet
  Dim s As Integer
  Dim findnext As Range
  
  Name = surname.Value
  Me.ListBox1.Clear
  Set ws = ThisWorkbook.Worksheets("Master")
  With ws
   Set f = .Cells(r, 1)
   Set findnext = f
  
  With ListBox1
    Do
  Debug.Print findnext.Address
  Set findnext = Range("A:A").findnext(findnext)
  
  .AddItem findnext.Value
  .List(.ListCount - 1, 1) = findnext.Offset(0, 1).Value
  .List(.ListCount - 1, 2) = findnext.Offset(0, 2).Value
  .List(.ListCount - 1, 3) = findnext.Offset(0, 3).Value
  .List(.ListCount - 1, 4) = findnext.Offset(0, 4).Value
  .List(.ListCount - 1, 5) = findnext.Offset(0, 5).Value
  .List(.ListCount - 1, 6) = findnext.Offset(0, 6).Value
  .List(.ListCount - 1, 7) = findnext.Offset(0, 7).Value
  .List(.ListCount - 1, 8) = findnext.Offset(0, 8).Value
  Loop While findnext.Address &lt;&gt; f.Address
   End With
  End With
  
  End Sub
  
  '----------------------------------------------------------------------------
  Public Sub update_Click()
  MsgBox "Directorate has been updated!"
  Dim Name As String
  Dim f As Range
  Dim ws As Worksheet
  
  Set ws = ThisWorkbook.Worksheets("Master")
  With ws
   Set f = .Cells(r, 1)
  
      f.Value = surname.Value
      f.Offset(0, 1).Value = firstname.Value
      f.Offset(0, 2).Value = tod.Value
      f.Offset(0, 3).Value = program.Value
      f.Offset(0, 4).Value = email.Value
      f.Offset(0, 5).Value = GetCheckBoxes
      f.Offset(0, 6).Value = officenumber.Value
      f.Offset(0, 7).Value = cellnumber.Value
  
  End With
  End Sub
  </code></pre>