Incorrect INDIRECT function

K

Ken

Hi Group,
Back for a simple (??) question:
I can format and color an entire row using this formula:
=INDIRECT("C"&ROW())="GMN"
however, that only works if "GMN" is all that is entered into the
cell. The "GMN" is actually followed by a string of 6-10 digits of
number, ex GMN 1234567890, and will be a different number on each
entry of GMN.....I've tried using a wildcard symbol (*) etc, but
cannot get it to work....I am currently using "Cell contains GMN" but
that just colors the cell....how would I color the whole row?? All
help greatly appreciated! Thanks to the group!
Ken
 
R

Ron Rosenfeld

Hi Group,
Back for a simple (??) question:
I can format and color an entire row using this formula:
=INDIRECT("C"&ROW())="GMN"
however, that only works if "GMN" is all that is entered into the
cell. The "GMN" is actually followed by a string of 6-10 digits of
number, ex GMN 1234567890, and will be a different number on each
entry of GMN.....I've tried using a wildcard symbol (*) etc, but
cannot get it to work....I am currently using "Cell contains GMN" but
that just colors the cell....how would I color the whole row?? All
help greatly appreciated! Thanks to the group!
Ken

Use FIND and check for a valid return to generate your True/False test:

Something like

=isnumber(find("GMN",indirect(...
--ron
 
K

Ken

Use FIND and check for a valid return to generate your True/False test:

Something like

=isnumber(find("GMN",indirect(...
--ron

Thanks, Ron!
What I used that worked is:
=FIND("GMN", INDIRECT("C"&ROW()))
Works exactly as I wanted...thanks for the hint on the "Find"....
Ken
 
R

Ron Rosenfeld

Thanks, Ron!
What I used that worked is:
=FIND("GMN", INDIRECT("C"&ROW()))
Works exactly as I wanted...thanks for the hint on the "Find"....
Ken

Glad it's working for you. Thanks for the feedback. By the way, if you need a
case insensitive version, just use SEARCH instead of FIND.
--ron
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top