ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Two If's - one in a range (https://www.excelbanter.com/excel-worksheet-functions/132437-two-ifs-one-range.html)

Shelly

Two If's - one in a range
 
I'm trying to do the following:

If E18=Yes
and If any cell F36 through F45 = ACS
Then
c8=Yes
and C9 = Yes

I've tried several things, but cannot get it to work.

Thanks!


CLR

Two If's - one in a range
 
Put this in C8...........

=IF(AND(COUNTIF(F36:F45,"ACS")0,E18="yes"),"Yes", "")

Vaya con Dios,
Chuck, CABGx3



"Shelly" wrote:

I'm trying to do the following:

If E18=Yes
and If any cell F36 through F45 = ACS
Then
c8=Yes
and C9 = Yes

I've tried several things, but cannot get it to work.

Thanks!


Shelly

Two If's - one in a range
 
Thanks, Chuck - however...

Now that I look at it closer... it's become more of a problem. Let me try
to explain...

Two worksheets: 1) Solution, 2) Services

The Solution worksheet has details about some services that are being
reported on. I need to copy part of the information from the Solution
worksheet to the Services worksheet based on criteria of one cell equaling
"ACS".

I'm needing to find certain rows that contain particular values: In the
range Solution!E36:E45, if any of the cells equal the value "ACS", I need to
copy the value in Solution!C# (where # is the same row) to Service:C8 cell,
and I need to copy the value in Solution !D# (where # is the same row) to
Service D8.

I need to copy this logic through 10 ranges in the Solution worksheet.

So...

If Solution!E36 = "ACS", copy Solution!C36 to Service!C8 and Solution!D36 to
Service!D8.

If Solution!E37 = "ACS", copy Solution!C37 to Service!C9 and Solution!D37 to
Service!D9.

If Solution!E38 = "ACS", copy Solution!C38 to Service!C10 and Solution!D38
to Service!D9.

Once the range Solution!E36:E45 has been processed, I need to repeat the
search through multiple ranges...
Solution!E45:E58
Solution!E62:E71
Solution!E88:E97
Solution!E101:E110
Solution!E114:E123
etc..... through
Solution!E192:E201

In the Services worksheet, I'm filling the range C8:D20... so the data
coming from the Solution worksheet is being plugged into these two columns
and 13 columns. The ranges correspond to each other like this:

Search Solution!E36:E45 -- Copy to Services!C8:D8
Search Solution!E49:E58 -- Copy to Services!C9:D9
Search Solution!E62:E71 -- Copy to Services!C10:D10
Search Solution!E75:E84 -- Copy to Services!C11:D11
etc through
Search Solution!E192:E201 -- Copy to Services!C20:D20

Any ideas? I've used some VBA code before, but I'm not an expert. Most of
what I used has been taken from this web site (either through questions I've
asked myself, or by adapting responses to other people).

Thanks.


All times are GMT +1. The time now is 11:04 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com