VBA Code
Private Sub UserForm_Initialize()
Me.TextBox1.SetFocus
End Sub
Me.TextBox1.Text = StrConv(Me.TextBox1.Text, vbProperCase)
Dim i As Long
Me.ListBox1.Clear
On Error Resume Next
For i = 1 To Application.WorksheetFunction.CountA(Sheet1.Range("A:A"))
a = Len(Me.TextBox1.Text)
If Left(Sheet1.Cells(i, 1).Text, a) = Left(Me.TextBox1.Text, a) Then
Me.ListBox1.AddItem Sheet1.Cells(i, 1).Value
Me.ListBox1.List(ListBox1.ListCount - 1, 1) = Sheet1.Cells(i, 2).Value
End If
Next i
End Sub
a minha len é sempre só 1 carácter?
ReplyDeleteIn the same userform how to select and add that searched item to another sheet,,, which code to apply for adding item from same list box to another sheet .sir please reply on this. By giving code. Of add item to another sheet...
ReplyDeleteFrom Pritesh
Sir if you will give that code through email then it will be useful for. Me... Pleased sir I am searching for this code. From more then 3 months and watched more then 100 videos from various channels....
Emailid:_priteshgala130@gmail.com
Watsapp: 8980543514
How do sum of column
ReplyDelete