Help whith Data parser

  • Thread starter Thread starter Tomkat743
  • Start date Start date
T

Tomkat743

what i am trying to do is have a formula or macro that can look in cell u4
then cell v4 then cell w4 and so on, if the cell contains a 1, 2 or -1
report the data in cell v1 to cell n4.

Each row has data from u to cs with about 500 rows of data. I have to parse
each row looking for a 1 or -1 or sometimes even a 2 or -2 then report the
value of the header row to one of 6 blank column rows n to s. There is a
maximum of 6 codes allowed per row hence the 6 blank column rows to show
data. I am trying to parse a spreadsheet designed by someone else so changing
the original layout is not an option.

Thank you in advance for any help on this.
 
Tonkat,

In cell N4, this looks for any occurence of 1 or 2....

=IF(OR(COUNTIF(U4:Z4,"*1*")>0,COUNTIF(U4:Z4,"*2*")>0),V1,"Not Found")

Though I have my doubts as to your problem statement.

HTH,
Bernie
MS Excel MVP
 
Thank you but that formula only looks for one instance in a row the row may
have up to 6 cells that contain either a 1 or a 2. Each time a number 1 or 2
is encountered i need it to report v1.
 
The formula looks at all six, and reports whether a 1 or 2 is found. Not
sure what you mean by "Each time" - do you have six different cells where
you want the formula?

Bernie
 
Back
Top