this is my formula
=IF(ISNUMBER(SEARCH("Lilac",G21)),150)+IF(ISNUMBER(SEARCH("Red",G21)),-50)
it returns a 0 , what do i need to add to it to return a blank cell instead ?
thanks in advance
this is my formula
=IF(ISNUMBER(SEARCH("Lilac",G21)),150)+IF(ISNUMBER(SEARCH("Red",G21)),-50)
it returns a 0 , what do i need to add to it to return a blank cell instead ?
thanks in advance
Can both Lilac and Red be present?
Dom
"May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."
Use code tags when posting your VBA code: [code] Your code here [/code]
Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.
So are Lilac and Red part of a longer text string? I'm just trying to ascertain the reason for using ISNUMBER/SEARCH and the best formula.
Dom
Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem, not your anticipated solution. Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.
To change a Title on your post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.
MOST PEOPLE REQUIRE HELP SO WHY PUT IT IN THE THREAD TITLE? EDITED FOR YOU
Hope that helps.
RoyUK
--------
For Excel Tips & Solutions, free examples and tutorials why not check out my web site
Free DataBaseForm example
Like this then:
=IF(ISNUMBER(SEARCH("Lilac",G21)),150,IF(ISNUMBER(SEARCH("Red",G21)),-50,""))
Dom
sorry didnt work, when i used this formula, i got a "150" placed in the cell?
to clarify the problem. the formula would go into say cell G22, when Cell G21 contains the text "Lilac" or "Red", it returns either a 150 if "Lilac" or "-50" if "Red" text is found. What happens though when it finds no text in cell G21 it shows a "0" in G22, i want it to give a blank cell instead.
thanks
Last edited by xlr8r; 09-30-2011 at 09:22 AM.
Really? It checks for Lilac, puts 150 in if found, if not checks for Red and puts -50 in if found and failing both those it'll return "".
Dom
thanks Dom
finally got it working.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks