This code needs to be in the ComboBox event SelectedIndexChanged.
Then get the index int i=ComboBox1.SelectedIndex; and look up the relevant row from the DataSet.
Also you can store the EmpIds in a global list and then use that to look up the Employee by Id.
If ComboBox1.SelectedIndex > -1 Then
Dim dv As DataView = CType(ComboBox1.DataSource, DataView)
For Each drv As DataRowView In dv
If drv.Item("EmpName") = CType(ComboBox1.SelectedItem, DataRowView).Item("EmpName") Then
TextBox1.Text = drv.Item("EmpID").ToString()
TextBox2.Text = drv.Item("Salry").ToString()
Exit For
End If
Next
End If