Hello sir,
I am using Visual studio 2005.
I am having more link labels on a form under a tabbed control.
I want to search for certain linklabels in a form. So i used the coding below, But it is displaying the search in the corresponding tabs itself. But i want my search to be displayed in new tab under the same tabbed control.
Can anyone help me in this?
Private Sub Button1_Click( _
ByVal sender As System.Object, _
ByVal e As System.EventArgs _
) Handles Button1.Click
For Each page As TabPage In Me.TabControl1.TabPages
For Each ctl As Control In page.Controls
If TypeOf ctl Is LinkLabel Then
ctl.Visible = (ctl.Text.IndexOf(txtSearch.Text, StringComparison.CurrentCultureIgnoreCase) <> -1)
End If
Next
Next
End Sub