macro to open find dialog box ready to search in values in workbook

Stuartzz

New Member
Joined
Nov 14, 2012
Messages
6
Hi there
I would like a macro that results in the find and replace dialog box being open with the following settings/characteristics:
-ready to search in “workbook”
-ready to search in “values”
-the text string “unfinished:*” in the “Find” field
-the cursor placed immediately after the aforementioned text string (if possible)

I don’t want the macro to execute a search, I want it to be ready for someone to type their name after the text string “unfinished:”.

Thanks for any assistance:)
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result
Hi there
I would like a macro that results in the find and replace dialog box being open with the following settings/characteristics:
-ready to search in workbook
-ready to search in values
-the text string unfinished: in the Find field, with the cursor placed immediately after the aforementioned text string

I don’t want the macro to execute a search, I want it to be ready for someone to type their name after the text string unfinished:

Thanks for your assistance 
 
Upvote 0
Hi there
I was thinking of a different approach that may be easier.

First have a macro (let's say macro 1) that brings up an input box that already has a "-" in the input field, and prompts the user with something like "enter your name after the "-" into the input field below and click OK". Then they follow the prompt by entering their name after the "-" and then when they click "OK" button in the input box, it launches another macro (macro 2) that contains code like below to execute a search in values in the whole workbook. The difference is that instead of executing a search with "-John", it would execute a search for the input from the input box in macro 1.
Also, after it executes the search, it should reopen the Excel find dialog box ready for someone to click "find next".

So I don't know how to macro 1, and I would need to know how to change my sample code for macro 2 so that it executes a search for the text entered into the input box during macro 1, and then reopens the "find" dialog box which will be ready for someone to click "find next" so it will search for the next instance of the same text in values in the whole workbook.

Could this work?

Any help would be great, thanks.

Stu

Code:
    Sheets("plan-master").Select
    Cells.Find(What:="-John", After:=ActiveCell, LookIn:=xlValues, LookAt:= _
        xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:=False _
        , SearchFormat:=False).Activate
 
Upvote 0

Forum statistics

Threads
1,224,824
Messages
6,181,187
Members
453,020
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top