ethicalhacker
Well-known member
Im using
to get the selected item on click of a button. I want to make sure that there is no error if the user clicks on the button without selecting an item, he should get a message "first select an item". Is there any kind of try catch exception I can use?
VB.NET:
Dim a As String = ListBox1.SelectedItem