I have a for each loop in vb.net for this particular example there are 2 items in list but after the first item the loop exits are there errors in the code
Public Function findUserID(ByVal list As List(Of KeyValuePair(Of String, String)), ByVal value As String)
Dim id As String = String.Empty
For Each kvp In list
If (kvp.Value = value) Then
id = kvp.Key
End If
Next
Return id
End Function
See Question&Answers more detail:os