Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
search word or text in excel spreadsheet
Hello
Could somebody help me. how could i find in the colomn A with an input box one word or sentence writen in the input box. Thanks for your help Louis |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
search word or text in excel spreadsheet
Try this:
Sub louis() Dim s As String Set r = Intersect(Range("A:A"), ActiveSheet.UsedRange) Set r2 = Nothing s = Application.InputBox(prompt:="enter string:", Type:=2) For Each rr In r If rr.Value = Replace(rr.Value, s, "") Then Else If r2 Is Nothing Then Set r2 = rr Else Set r2 = Union(r2, rr) End If End If Next If r2 Is Nothing Then MsgBox ("Nothing Found") Else r2.Select End If End Sub -- Gary''s Student - gsnu200765 "Louis" wrote: Hello Could somebody help me. how could i find in the colomn A with an input box one word or sentence writen in the input box. Thanks for your help Louis |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Search text field for word | Excel Discussion (Misc queries) | |||
Capturing a word sequence as part of a text in a spreadsheet cell | Excel Worksheet Functions | |||
how to search a word in a excel file which appears twice | Excel Discussion (Misc queries) | |||
Excel - let search for more than one disconnected word in a cell | Excel Worksheet Functions | |||
need formula to search column for a word and return another word | Excel Discussion (Misc queries) |