Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cell contents check and prompt out message (By using Macro)
Hi all,
Could you know how to use Macro to check the cell contents with specified "String" and prompt out Message box? E.g. If the Column B1 = "USA" and Column H1 ="Mexico" , prompt the message box "USA and Mexico are found". Thanks, Tlee |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cell contents check and prompt out message (By using Macro)
I'm thinking you want something like this
Msgbox(Range("B1") & " and " & range("H1") & " are found.") This assumes that these ranges are on your active sheet. "tlee" wrote: Hi all, Could you know how to use Macro to check the cell contents with specified "String" and prompt out Message box? E.g. If the Column B1 = "USA" and Column H1 ="Mexico" , prompt the message box "USA and Mexico are found". Thanks, Tlee |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cell contents check and prompt out message (By using Macro)
I've used the examples here
http://www.cpearson.com/excel/vbe.aspx to get to Modules and Procedures. Try it and if it doesn't work, come back and post what you have. HTH, Barb Reinhardt "tlee" wrote: Hi all, Could you know how to use Macro to check the cell contents with specified "String" and prompt out Message box? E.g. If the Column B1 = "USA" and Column H1 ="Mexico" , prompt the message box "USA and Mexico are found". Thanks, Tlee |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cell contents check and prompt out message (By using Macro)
This was a reply to another post.
"Barb Reinhardt" wrote: I've used the examples here http://www.cpearson.com/excel/vbe.aspx to get to Modules and Procedures. Try it and if it doesn't work, come back and post what you have. HTH, Barb Reinhardt "tlee" wrote: Hi all, Could you know how to use Macro to check the cell contents with specified "String" and prompt out Message box? E.g. If the Column B1 = "USA" and Column H1 ="Mexico" , prompt the message box "USA and Mexico are found". Thanks, Tlee |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cell contents check and prompt out message (By using Macro)
Barb,
Thanks for your help and information. I would like to use control flow to check the cell "B1" and "H1" such as if statement. After checked, promot message or continous run the code. Thanks Tlee I'm thinking you want something like this Msgbox(Range("B1") & " and " & range("H1") & " are found.") This assumes that these ranges are on your active sheet. "tlee" wrote: Hi all, Could you know how to use Macro to check the cell contents with specified "String" and prompt out Message box? E.g. If the Column B1 = "USA" and Column H1 ="Mexico" , prompt the message box "USA and Mexico are found". Thanks, Tlee |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Incorpoarting cell contents into a message box | Excel Discussion (Misc queries) | |||
vba to check cell contents | Excel Discussion (Misc queries) | |||
check cell contents | Excel Programming | |||
how do i create a macro that would check the contents of cells | Excel Discussion (Misc queries) | |||
how do i create a macro that would check the contents of cells | Excel Discussion (Misc queries) |