ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   multi text search question (https://www.excelbanter.com/excel-programming/339217-multi-text-search-question.html)

gomo666

multi text search question
 
Hi, I just start learning Excel programming. What I want to do is to search
the whole worksheet by keyword like "today*is*monday", and copy the cell to
another worksheet.

Also I do not know how to make a window for typing those key words. Any
help? Thanks

Dave Peterson

multi text search question
 
You can use a line like:

Dim SearchFor as string
searchfor = inputbox(Prompt:="What's the Word, Kenny?")
if trim(searchfor)="" then
exit sub 'user hit cancel
end if

Someday, you may want to get a few responses from the user. After a while,
these inputboxes become kind of a pain. You may want to design a userform to
get that kind of input (and you could use it for just one thing, too).

Debra Dalgleish has a small tutorial at:
http://contextures.com/xlUserForm01.html



gomo666 wrote:

Hi, I just start learning Excel programming. What I want to do is to search
the whole worksheet by keyword like "today*is*monday", and copy the cell to
another worksheet.

Also I do not know how to make a window for typing those key words. Any
help? Thanks


--

Dave Peterson


All times are GMT +1. The time now is 06:18 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com