Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro with count if
Hi: I want to create a macro that counts the rows wich have -P in any part of the word. I will create 2 variables PU= total of rows with -P and IN=total of rows without -P. A CCNG-PU CNDLF DLKJFOE CNFIE-PU 3540-PU DLREI Could anyone help me with it please. Thanks in advance Orquidea |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro with count if
PU=Activesheet.Evaluate("SUMPRODUCT(--(ISNUMBER(SEARCH("-P",A2:A200))))")
IN = Application.COUNTA(A:A) - PU -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "orquidea" wrote in message ... Hi: I want to create a macro that counts the rows wich have -P in any part of the word. I will create 2 variables PU= total of rows with -P and IN=total of rows without -P. A CCNG-PU CNDLF DLKJFOE CNFIE-PU 3540-PU DLREI Could anyone help me with it please. Thanks in advance Orquidea |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Macro with count if
Hi Bob
Thanks for your help. I was trying the subprocedure but a "syntax error" pops up in the first line, it highlights this part.("-P",A2:A200))))") Could you please help to make it work? Thanks in advance. "Bob Phillips" wrote: PU=Activesheet.Evaluate("SUMPRODUCT(--(ISNUMBER(SEARCH("-P",A2:A200))))") IN = Application.COUNTA(A:A) - PU -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "orquidea" wrote in message ... Hi: I want to create a macro that counts the rows wich have -P in any part of the word. I will create 2 variables PU= total of rows with -P and IN=total of rows without -P. A CCNG-PU CNDLF DLKJFOE CNFIE-PU 3540-PU DLREI Could anyone help me with it please. Thanks in advance Orquidea |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
help to count by macro or whatever simple and easy.... | Excel Discussion (Misc queries) | |||
Count Rows macro | Excel Discussion (Misc queries) | |||
Why is my macro changing sum to count? | Excel Discussion (Misc queries) | |||
Need a word-count macro for excel | Excel Discussion (Misc queries) | |||
Is there a word-count macro in excel? | Excel Discussion (Misc queries) |