Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click hashtable.Add(1001, "A") hashtable.Add(1002, "B") hashtable.Add(1003, "C") hashtable.Add(1004, "D")
MessageBox.Show(Exchange(1001))
End Sub
Public Function Exchange(ByVal source As Integer) As String Return hashtable.Item(source).ToString End Function