Hi I need a help,
I created a program for search result,
Here I have two button. 1) SEARCH 2 ) DELETE
When I click on search, all record will be displayed in the table.
And I can select a record to delete.
But If I am not select a record, and when I click on delete button, First record is deleted automatically or
first record is selected automatically to delete.
I don't want that type of deletion, deletion only after select a record.
My code is give below.
I want this program as when I press delete button, with out selection any record, any record won't be deleted.
Sub deleteStudent_Click
If SearchingStudent.RowCount <= SearchingStudent.SelectedRow Then Return
name = SearchingStudent.Cell (SearchingStudent.ColName(1),SearchingStudent.SelectedRow)
address = SearchingStudent.Cell (SearchingStudent.ColName(2),SearchingStudent.SelectedRow)
Msgbox(name)
Msgbox(address)
End Sub
Thanks and regards
Aru