Formula Help! Evaluation cells that contain certain text

missdeannamarie

New Member
Joined
Mar 31, 2014
Messages
25
Hello!! I am hoping you excel genius' can help a girl out!!! I have tried to explain below my situation. Please offer any help you think you can! Much appreciated.


TAB 1: Data is entered manually in cells B2:J3
The data in the cells is as follows:​
AA: BB: CC, CC​
Where AA is the Location of the Project, BB is the Tool, and CC are the employee's assigned to the project.​
ABCDEFGHIJ
1PROJECT6/1/176/2/176/3/176/4/176/5/176/6/176/7/176/8/176/9/17
2P1
PC: F3: KW,MGPC: F3: KW,MGPC: F3: KW,MGPC: F3: KW,MGPC: F3: KW,MGPC: F3: KW,MGPC: F3: KW,MG
3P2CS: F1: KW,DLCS: F1: KW,DLCS: F1: KW,DLCS: F1: KW,DLCS: F1: KW,DL

<tbody>
</tbody>


TAB 2: This is where I want to enter the formula. I want this to act as a resource tool, that will show when each employee (CC) is scheduled for a project. I have one formula that works to tell me if an employee is double booked, but i want to add to this.

=IF(COUNTIF(TAB1!B2:B3,"*"&$A$2&"*")=1,"Z",IF(COUNTIF(TAB1!B2:B3,"*"&$A$2&"*")>1,"X",""))
Where Z = Booked once, X = Booked more than once

I want to add to this the ability to code the booked one as its location (AA) form TAB 1. This is where I need help! :)
I was trying something like this, but couldn't get it to work:
=IF(AND(B57:B58="PC",B57:B58="KW"),"V", "")

Once I have the letters returned, I then conditional format based on that for color coding.

ABCDEFGHIJ
1EMPLOYEE6/1/176/2/176/3/176/4/176/5/176/6/176/7/176/8/176/9/17
2KW
3MG
4DL

<tbody>
</tbody>

Hope this makes sense!! Thanks a lot!!
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
What is the value that must appear in B2 of TAB2, given the sample from TAB1?

So my goal is to have several different options:


Since the AA data in the example in TAB1 can have several different options, I want the value in B2 to have several options as well.

So for example:

In cell B2: Since "PC" is the (AA) value in TAB 1 B2, I'd like it to return "Z", if it was "CS" instead it would return "V". However, if the employee "KW" is listed more than once in the TAB 1 data range, I want it to override the other values and return "X" for example.

That's why the first formula I have works, however I don't have the option to add different values for different (AA) values.

So my vision would be this as the return:

ABCDEFGHIJ
1EMPLOYEE6/1/176/2/176/3/176/4/176/5/176/6/176/7/176/8/176/9/17
2KWZZZZXXXVV
3MGZZZZZZZ
4DLVVVVV

<tbody>
</tbody>

Thanks!!!!
 
Upvote 0
In B2 of TAB2 control+shift+enter, not just enter, copy across, and down:

=CHOOSE(SUM(IF(ISNUMBER(SEARCH($A2&",",SUBSTITUTE(INDEX('TAB1'!$B$2:$J$3,0,MATCH(B$1,'TAB1'!$B$1:$J$1,0))," ",",")&",")),1))+1,"",LOOKUP(9.99E+307,SEARCH({"PC:";"CS:"},LEFT(IF(ISNUMBER(SEARCH($A2&",",SUBSTITUTE(INDEX('TAB1'!$B$2:$J$3,0,MATCH(B$1,'TAB1'!$B$1:$J$1,0))," ",",")&",")),SUBSTITUTE(INDEX('TAB1'!$B$2:$J$3,0,MATCH(B$1,'TAB1'!$B$1:$J$1,0))," ",",")&","),3)),{"Z";"V"}),"X")
 
Upvote 0
In B2 of TAB2 control+shift+enter, not just enter, copy across, and down:

=CHOOSE(SUM(IF(ISNUMBER(SEARCH($A2&",",SUBSTITUTE(INDEX('TAB1'!$B$2:$J$3,0,MATCH(B$1,'TAB1'!$B$1:$J$1,0))," ",",")&",")),1))+1,"",LOOKUP(9.99E+307,SEARCH({"PC:";"CS:"},LEFT(IF(ISNUMBER(SEARCH($A2&",",SUBSTITUTE(INDEX('TAB1'!$B$2:$J$3,0,MATCH(B$1,'TAB1'!$B$1:$J$1,0))," ",",")&",")),SUBSTITUTE(INDEX('TAB1'!$B$2:$J$3,0,MATCH(B$1,'TAB1'!$B$1:$J$1,0))," ",",")&","),3)),{"Z";"V"}),"X")

That worked thank you! If I want to add additional "AA" values, how would I do that? Just continue the sequence you have?

I have 8 different "AA" values I'd like to use.
 
Upvote 0
That worked thank you!

You are welcome.

If I want to add additional "AA" values, how would I do that? Just continue the sequence you have?

I have 8 different "AA" values I'd like to use.

Yes. You could use a vertical list for each. A vertical range of 8 cells named SList, another names RList, and plug these in the appropriate places, i.e.

SList >> {"PC:","CS:"}
RList >> {"Z";"V"}

An SList item is expected to be 3 char long including a colon at the end.
 
Upvote 0

Forum statistics

Threads
1,215,507
Messages
6,125,212
Members
449,214
Latest member
mr_ordinaryboy

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top