Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Worksheet Functions / September 2007

Tip: Looking for answers? Try searching our database.

Find Function

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
sargum@umich.edu - 10 Sep 2007 18:49 GMT
Hi,

Is there any way to integrate the "Find" Dialogue box right into the
Excel file such that it is always visible?
I want users to be able to find a file based on a key word entry (much
like they would do with ctrl + F).

Please note that I do not want a Find/Replace function, just Find, No
replace.  I mention this b/c I noticed that there is something out
there that is available that allows for a find/replace but I just want
Find.

Thanks.

S
Roger Govier - 14 Sep 2007 13:41 GMT
Hi Sargum

As I have your file for dealing with Filtering (as per your other thread), I
have written a small macro for you and attached it to a button on the sheet.
The file has been emailed to you.

Sub FindItem()

  On Error GoTo FindItem_Error

   Selection.Interior.ColorIndex = xlNone
   Cells.Find(what:=Range("C1").Value, _
   After:=ActiveCell, LookIn:=xlFormulas, _
   LookAt:=xlPart, SearchOrder:=xlByRows, _
   SearchDirection:=xlNext, MatchCase:= _
       False, SearchFormat:=False).Activate
nextfind:
   ActiveCell.Select
      With Selection.Interior
       .ColorIndex = 36
       .Pattern = xlSolid
       .PatternColorIndex = xlAutomatic
      End With

   Select Case MsgBox("Do you want to continue searching", _
   vbYesNo Or vbQuestion Or vbDefaultButton1, "Find Details")

       Case vbYes
       Selection.Interior.ColorIndex = xlNone
       Cells.FindNext(After:=ActiveCell).Activate
       GoTo nextfind
       Case vbNo
       Selection.Interior.ColorIndex = xlNone
   End Select

  On Error GoTo 0
  Exit Sub

FindItem_Error:

   MsgBox "Error " & Err.Number & " (" & Err.Description & _
   ") in procedure FindItem of Module Module1"

End Sub

Signature

Regards
Roger Govier

> Hi,
>
[quoted text clipped - 11 lines]
>
> S
sargum@umich.edu - 14 Sep 2007 20:26 GMT
On Sep 14, 8:41 am, "Roger Govier" <rogerattechnology4NOSPAMu.co.uk>
wrote:
> Hi Sargum
>
[quoted text clipped - 66 lines]
>
> - Show quoted text -

Thanks Roger,  this is exactly what I was looking for!!

Sargum
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.