General information
Category:
The Mere Mortals .NET Framework
Hi Tim. You're correct about what the user might/can do after a search. I'm not refreshing the grid. I can see the "Added" record being removed before the application errors out. The only thing I'm doing with the primary bo is performing a search and add/delete records. I have no code in any of the buttons, except for the "Search" button.
Private Sub btnSearch_Click(sender As System.Object, e As System.EventArgs) Handles btnSearch.Click
If Me.txtSearchName.Text "NOT EQUAL" String.Empty Then
Me._employee.SearchEmployeeByName(Me.txtSearchName.Text)
If Me._employee.EntityList.Count = 0 Then
Me.ShowMessage("Your search resulted in no matching records.")
Me.txtSearchName.Focus()
Me.txtSearchName.Text = String.Empty
Else
Me.txtName.Focus()
End If
Else
Me.ShowMessage("You must enter an employee name to peform a search.")
End If
End Sub
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only