conditional formatting question

biglb79

Active Member
Joined
Oct 17, 2007
Messages
299
I'm hoping someone can help me with this. I want to have a row highlighted yellow in columns A:T if the patient name in column I and MRAdmit number in column H appear on the prior period unbilled tab

the prior period unbilled tab has data in columns A:AF and the patient name appears in column E while the MRAdmit number appears in column A
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
something like
as a rule
countifs('prior period unbilled'!$E$2:$E$100000, $I2, 'prior period unbilled'!$A$2:$A$100000, $H2)>0 - change the rows 100000 to whatever the maximum possible rows are
I prefer not to use full column reference for performance BUT you could use that
countifs('prior period unbilled'!$E:$E, $I2, 'prior period unbilled'!$A:$A, $H2)>0

or 2007, 2010 , 2013 , 2016 , 2019 or 365 Subscription excel version
Conditional Formatting

Highlight applicable range >>
A2:T10000 - Change, reduce or extend the rows to meet your data range of rows

Home Tab >> Styles >> Conditional Formatting
New Rule >> Use a formula to determine which cells to format
Edit the Rule Description: Format values where this formula is true:
=countifs('prior period unbilled'!$E$2:$E$100000, $I2, 'prior period unbilled'!$A$2:$A$100000, $H2)>0

Format [Number, Font, Border, Fill] - FILL YELLOW
choose the format you would like to apply when the condition is true
OK >> OK
change the name 'prior period unbilled' to whatever the name of the sheet is

Note: Images are difficult to see , and also requires that I input all the data myself, which means I may make an error, which is very time consuming, and from my point of view less likely to get a response, if a complicated spreadsheet. Plus we cannot see any of the formulas used.

Therefore -

A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

This will possibly enable a quicker and more accurate solution for you.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
 
Upvote 0
Maybe this:

Change "Sheet3" to your sheet name.
Book1
ABCDEFGHIJKLMNOPQRST
1MRAdmitPatient
212345Joe
345678Jane
412345Joe
Sheet2
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A2:T10Expression=AND($I2<>"",MATCH($H2&$I2,Sheet3!$A$2:$A$10&Sheet3!$E$2:$E$10,0))textNO
 
Upvote 0
something like
as a rule
countifs('prior period unbilled'!$E$2:$E$100000, $I2, 'prior period unbilled'!$A$2:$A$100000, $H2)>0 - change the rows 100000 to whatever the maximum possible rows are
I prefer not to use full column reference for performance BUT you could use that
countifs('prior period unbilled'!$E:$E, $I2, 'prior period unbilled'!$A:$A, $H2)>0

or 2007, 2010 , 2013 , 2016 , 2019 or 365 Subscription excel version
Conditional Formatting

Highlight applicable range >>
A2:T10000 - Change, reduce or extend the rows to meet your data range of rows

Home Tab >> Styles >> Conditional Formatting
New Rule >> Use a formula to determine which cells to format
Edit the Rule Description: Format values where this formula is true:
=countifs('prior period unbilled'!$E$2:$E$100000, $I2, 'prior period unbilled'!$A$2:$A$100000, $H2)>0

Format [Number, Font, Border, Fill] - FILL YELLOW
choose the format you would like to apply when the condition is true
OK >> OK
change the name 'prior period unbilled' to whatever the name of the sheet is

Note: Images are difficult to see , and also requires that I input all the data myself, which means I may make an error, which is very time consuming, and from my point of view less likely to get a response, if a complicated spreadsheet. Plus we cannot see any of the formulas used.

Therefore -

A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

This will possibly enable a quicker and more accurate solution for you.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
I think I figured out the XL2BB

Book6
ABCDEFGHIJKLMNOPQRST
3TransactionLedgerDebit G/L AcctCredit G/L AcctG/L DateTrans IDService DateMRAdmitPatient NameAdmit DateDischarge DateProgramPayor NamePayorSite NameFinclass CodeService CodeDescription Gross Amount Net Amount System
4CHGSTANDARD130-07-000-05300-07-301-051/3/202411980451/3/20245501086-1Soprano, Tony9/8/20231/29/2024MH IOPMGD MCAIDno
5CHGSTANDARD130-07-000-05300-07-301-051/3/202411980441/3/20245501267-4Soprano, Carmela9/8/20231/29/2024MH IOPMGD MCAIDno
6CHGSTANDARD130-07-000-05300-07-301-051/3/202411980431/3/20245501550-1Sorpano, AJ9/20/20231/19/2024MH IOPMGD MCAIDno
7CHGSTANDARD130-07-000-05300-07-301-051/3/202411980421/3/20245501883-2Soprano, Meadow11/3/20231/18/2024MH IOPMGD MCAIDno
8CHGSTANDARD130-01-000-05300-01-301-051/3/202411980411/3/20245500362-1Soprano, Janice12/7/2023MH IOPMGD MCAREno
9CHGSTANDARD130-07-000-05300-07-301-051/3/202411980401/3/20245500394-3Maltisonti, Christopher12/18/2023MH IOPMGD MCAIDno
10CHGSTANDARD130-04-000-05300-04-301-051/5/202411980391/5/20245501194-2Walnuts, Paulie12/11/2023MH IOPBCBSno
11CHGSTANDARD130-07-000-05300-07-301-051/5/202411980381/5/20245500840-3Sack, Johnny9/8/20231/29/2024MH IOPMGD MCAIDno
12CHGSTANDARD130-07-000-05300-07-301-051/5/202411980371/5/20245501194-2Dante, Silvio9/20/20231/19/2024MH IOPMGD MCAIDno
13CHGSTANDARD130-07-000-05300-07-301-051/5/202411980361/5/20245500840-3Bucco, Artie11/3/20231/18/2024MH IOPMGD MCAIDno
14CHGSTANDARD130-01-000-05300-01-301-051/5/202411980351/5/20245501714-1Melfie, Doctor12/7/2023MH IOPMGD MCAREno
15CHGSTANDARD130-07-000-05300-07-301-051/5/202411980341/5/20245500218-3La Cerva, Adriana9/8/20231/29/2024MH IOPMGD MCAIDno
16CHGSTANDARD130-01-000-05300-01-301-051/5/202411980331/5/20245502228-2Leotardo, Phil12/7/2023MH IOPMGD MCAREno
17CHGSTANDARD130-07-000-05300-07-301-051/8/202411980321/8/20245500218-3Giunta, Furio9/8/20231/29/2024MH IOPMGD MCAIDno
18CHGSTANDARD130-07-000-05300-07-301-051/8/202411980311/8/20245501230-3Soprano, Livia9/20/20231/19/2024MH IOPMGD MCAIDno
19CHGSTANDARD130-01-000-05300-01-301-051/8/202411980301/8/20245502228-2Ciferetto, Ralph12/7/2023MH IOPMGD MCAREno
20CHGSTANDARD130-07-000-05300-07-301-051/8/202411980291/8/20245500794-4Bacalla, Bobby12/18/2023MH IOPMGD MCAIDno
SVH ChargeGL
 
Upvote 0
I think I figured out the XL2BB

Book6
ABCDEFGHIJKLMNOPQRST
3TransactionLedgerDebit G/L AcctCredit G/L AcctG/L DateTrans IDService DateMRAdmitPatient NameAdmit DateDischarge DateProgramPayor NamePayorSite NameFinclass CodeService CodeDescription Gross Amount Net Amount System
4CHGSTANDARD130-07-000-05300-07-301-051/3/202411980451/3/20245501086-1Soprano, Tony9/8/20231/29/2024MH IOPMGD MCAIDno
5CHGSTANDARD130-07-000-05300-07-301-051/3/202411980441/3/20245501267-4Soprano, Carmela9/8/20231/29/2024MH IOPMGD MCAIDno
6CHGSTANDARD130-07-000-05300-07-301-051/3/202411980431/3/20245501550-1Sorpano, AJ9/20/20231/19/2024MH IOPMGD MCAIDno
7CHGSTANDARD130-07-000-05300-07-301-051/3/202411980421/3/20245501883-2Soprano, Meadow11/3/20231/18/2024MH IOPMGD MCAIDno
8CHGSTANDARD130-01-000-05300-01-301-051/3/202411980411/3/20245500362-1Soprano, Janice12/7/2023MH IOPMGD MCAREno
9CHGSTANDARD130-07-000-05300-07-301-051/3/202411980401/3/20245500394-3Maltisonti, Christopher12/18/2023MH IOPMGD MCAIDno
10CHGSTANDARD130-04-000-05300-04-301-051/5/202411980391/5/20245501194-2Walnuts, Paulie12/11/2023MH IOPBCBSno
11CHGSTANDARD130-07-000-05300-07-301-051/5/202411980381/5/20245500840-3Sack, Johnny9/8/20231/29/2024MH IOPMGD MCAIDno
12CHGSTANDARD130-07-000-05300-07-301-051/5/202411980371/5/20245501194-2Dante, Silvio9/20/20231/19/2024MH IOPMGD MCAIDno
13CHGSTANDARD130-07-000-05300-07-301-051/5/202411980361/5/20245500840-3Bucco, Artie11/3/20231/18/2024MH IOPMGD MCAIDno
14CHGSTANDARD130-01-000-05300-01-301-051/5/202411980351/5/20245501714-1Melfie, Doctor12/7/2023MH IOPMGD MCAREno
15CHGSTANDARD130-07-000-05300-07-301-051/5/202411980341/5/20245500218-3La Cerva, Adriana9/8/20231/29/2024MH IOPMGD MCAIDno
16CHGSTANDARD130-01-000-05300-01-301-051/5/202411980331/5/20245502228-2Leotardo, Phil12/7/2023MH IOPMGD MCAREno
17CHGSTANDARD130-07-000-05300-07-301-051/8/202411980321/8/20245500218-3Giunta, Furio9/8/20231/29/2024MH IOPMGD MCAIDno
18CHGSTANDARD130-07-000-05300-07-301-051/8/202411980311/8/20245501230-3Soprano, Livia9/20/20231/19/2024MH IOPMGD MCAIDno
19CHGSTANDARD130-01-000-05300-01-301-051/8/202411980301/8/20245502228-2Ciferetto, Ralph12/7/2023MH IOPMGD MCAREno
20CHGSTANDARD130-07-000-05300-07-301-051/8/202411980291/8/20245500794-4Bacalla, Bobby12/18/2023MH IOPMGD MCAIDno
SVH ChargeGL
and here is the 2nd tab

Book6
ABCDEFGHIKLMNOPRXYACADAEAF
1MR-Admit#Admit DateDischarge DateDischarge StatusPatient NameG/L DateService DateService CodeBill DateCharge DescriptionProgramDepartmentFinClassPayorLocationGross RateNet RateExtended NetC/A Reserve AmtPosted W/OW/O Reserve Amt
25501086-16/1/20237/14/20231Soprano, Tony7/13/20237/13/2023MGD MCAID
35501267-410/24/202311/13/20231Soprano, Carmela10/27/202310/27/2023MCAID
45501550-18/29/20239/15/20231Sorpano, AJ9/11/20239/11/2023MGD MCAID
55501883-212/17/2023Soprano, Meadow12/31/202312/31/2023MGD MCAID
65500362-112/11/202212/19/20221Soprano, Janice12/18/202212/18/2022MGD MCAID
75500394-312/15/202312/26/20231Maltisonti, Christopher12/18/202312/18/2023MGD MCAID
85501194-212/6/202312/14/20231Walnuts, Paulie12/13/202312/13/2023MGD MCAID
95500840-312/20/202312/28/20231Sack, Johnny12/27/202312/27/2023MGD MCAID
105501194-212/6/202312/14/20231Dante, Silvio12/6/202312/6/2023MGD MCAID
115500840-312/20/202312/28/20231Bucco, Artie12/26/202312/26/2023MGD MCAID
125501714-19/27/202310/7/20231Melfie, Doctor9/27/20239/27/2023MGD MCAID
135501772-110/11/202310/19/20231La Cerva, Adriana10/12/202310/12/2023MGD MCARE
145502343-112/19/202312/24/20231Leotardo, Phil12/21/202312/21/2023COMM
155500218-39/8/2023Giunta, Furio12/6/202312/6/2023MGD MCAID
165502361-112/24/202312/29/20231Soprano, Livia12/24/202312/24/2023SELF-PAY
175502361-112/24/202312/29/20231Ciferetto, Ralph12/25/202312/25/2023SELF-PAY
185502361-112/24/202312/29/20231Bacalla, Bobby12/26/202312/26/2023SELF-PAY
prior period unbilled
 
Upvote 0
the formula i posted should work in conditional formatting

cond-frmt-ETAF.xlsx
ABCDEFGHIJKLMNOPQRST
1TransactionLedgerDebit G/L AcctCredit G/L AcctG/L DateTrans IDService DateMRAdmitPatient NameAdmit DateDischarge DateProgramPayor NamePayorSite NameFinclass CodeService CodeDescription Gross Amount Net Amount System
2CHGSTANDARD130-07-000-05300-07-301-05452941198045452945501086-1Soprano, Tony4517745320MH IOPMGD MCAIDno
3CHGSTANDARD130-07-000-05300-07-301-05452941198044452945501267-4Soprano, Carmela4517745320MH IOPMGD MCAIDno
4CHGSTANDARD130-07-000-05300-07-301-05452941198043452945501550-1Sorpano, AJ4518945310MH IOPMGD MCAIDno
5CHGSTANDARD130-07-000-05300-07-301-05452941198042452945501883-2Soprano, Meadow4523345309MH IOPMGD MCAIDno
6CHGSTANDARD130-01-000-05300-01-301-05452941198041452945500362-1Soprano, Janice45267MH IOPMGD MCAREno
7CHGSTANDARD130-07-000-05300-07-301-05452941198040452945500394-3Maltisonti, Christopher45278MH IOPMGD MCAIDno
8CHGSTANDARD130-04-000-05300-04-301-05452961198039452965501194-2Walnuts, Paulie45271MH IOPBCBSno
9CHGSTANDARD130-07-000-05300-07-301-05452961198038452965500840-3Sack, Johnny4517745320MH IOPMGD MCAIDno
10CHGSTANDARD130-07-000-05300-07-301-05452961198037452965501194-2Dante, Silvio4518945310MH IOPMGD MCAIDno
11CHGSTANDARD130-07-000-05300-07-301-05452961198036452965500840-3Bucco, Artie4523345309MH IOPMGD MCAIDno
12CHGSTANDARD130-01-000-05300-01-301-05452961198035452965501714-1Melfie, Doctor45267MH IOPMGD MCAREno
13CHGSTANDARD130-07-000-05300-07-301-05452961198034452965500218-3La Cerva, Adriana4517745320MH IOPMGD MCAIDno
14CHGSTANDARD130-01-000-05300-01-301-05452961198033452965502228-2Leotardo, Phil45267MH IOPMGD MCAREno
15CHGSTANDARD130-07-000-05300-07-301-05452991198032452995500218-3Giunta, Furio4517745320MH IOPMGD MCAIDno
16CHGSTANDARD130-07-000-05300-07-301-05452991198031452995501230-3Soprano, Livia4518945310MH IOPMGD MCAIDno
17CHGSTANDARD130-01-000-05300-01-301-05452991198030452995502228-2Ciferetto, Ralph45267MH IOPMGD MCAREno
18CHGSTANDARD130-07-000-05300-07-301-05452991198029452995500794-4Bacalla, Bobby45278MH IOPMGD MCAIDno
19
20
21
22
23
24
Sheet2
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A2:T100Expression=COUNTIFS('Prior Period UnBilled'!$E$2:$E$100000, $I2, 'Prior Period UnBilled'!$A$2:$A$100000, $H2)>0textNO


based on the 2nd sheet
 
Upvote 0
the formula i posted should work in conditional formatting

cond-frmt-ETAF.xlsx
ABCDEFGHIJKLMNOPQRST
1TransactionLedgerDebit G/L AcctCredit G/L AcctG/L DateTrans IDService DateMRAdmitPatient NameAdmit DateDischarge DateProgramPayor NamePayorSite NameFinclass CodeService CodeDescription Gross Amount Net Amount System
2CHGSTANDARD130-07-000-05300-07-301-05452941198045452945501086-1Soprano, Tony4517745320MH IOPMGD MCAIDno
3CHGSTANDARD130-07-000-05300-07-301-05452941198044452945501267-4Soprano, Carmela4517745320MH IOPMGD MCAIDno
4CHGSTANDARD130-07-000-05300-07-301-05452941198043452945501550-1Sorpano, AJ4518945310MH IOPMGD MCAIDno
5CHGSTANDARD130-07-000-05300-07-301-05452941198042452945501883-2Soprano, Meadow4523345309MH IOPMGD MCAIDno
6CHGSTANDARD130-01-000-05300-01-301-05452941198041452945500362-1Soprano, Janice45267MH IOPMGD MCAREno
7CHGSTANDARD130-07-000-05300-07-301-05452941198040452945500394-3Maltisonti, Christopher45278MH IOPMGD MCAIDno
8CHGSTANDARD130-04-000-05300-04-301-05452961198039452965501194-2Walnuts, Paulie45271MH IOPBCBSno
9CHGSTANDARD130-07-000-05300-07-301-05452961198038452965500840-3Sack, Johnny4517745320MH IOPMGD MCAIDno
10CHGSTANDARD130-07-000-05300-07-301-05452961198037452965501194-2Dante, Silvio4518945310MH IOPMGD MCAIDno
11CHGSTANDARD130-07-000-05300-07-301-05452961198036452965500840-3Bucco, Artie4523345309MH IOPMGD MCAIDno
12CHGSTANDARD130-01-000-05300-01-301-05452961198035452965501714-1Melfie, Doctor45267MH IOPMGD MCAREno
13CHGSTANDARD130-07-000-05300-07-301-05452961198034452965500218-3La Cerva, Adriana4517745320MH IOPMGD MCAIDno
14CHGSTANDARD130-01-000-05300-01-301-05452961198033452965502228-2Leotardo, Phil45267MH IOPMGD MCAREno
15CHGSTANDARD130-07-000-05300-07-301-05452991198032452995500218-3Giunta, Furio4517745320MH IOPMGD MCAIDno
16CHGSTANDARD130-07-000-05300-07-301-05452991198031452995501230-3Soprano, Livia4518945310MH IOPMGD MCAIDno
17CHGSTANDARD130-01-000-05300-01-301-05452991198030452995502228-2Ciferetto, Ralph45267MH IOPMGD MCAREno
18CHGSTANDARD130-07-000-05300-07-301-05452991198029452995500794-4Bacalla, Bobby45278MH IOPMGD MCAIDno
19
20
21
22
23
24
Sheet2
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A2:T100Expression=COUNTIFS('Prior Period UnBilled'!$E$2:$E$100000, $I2, 'Prior Period UnBilled'!$A$2:$A$100000, $H2)>0textNO


based on the 2nd sheet
for some reason I can't get it to work. could it be because of the format for the name and MRAdmit# being a general format?
 
Upvote 0
no , if same in both

what happens - the formula needs to start with th esame row number as the selection

Highlight applicable range >>
A2:T10000 - Change, reduce or extend the rows to meet your data range of rows

so as you have selected row 2 here , then the bit its matching with on needs to be row 2
the other sheet can be anything for that range
so it could be on the other sheet starting at row 10 - doesnt matter so long as its the correct range
=countifs('prior period unbilled'!$E$10:$E$100000, $I2, 'prior period unbilled'!$A$10:$A$100000, $H2)>0

the orange bits need to be the same row number as the selection for conditional formatting
Also the $ are important on the columns as well

on a drop box link for a couple of days
 
Upvote 0
am I typing this incorrectly? I did conditional formatting use a formula for a rule after highlighting A4:T4 (will copy down once I have it working on the top row)

="""countifs('prior period unbilled'!$E:$E, $I4, 'prior period unbilled'!$A:$A, $H4)>0"
 
Upvote 0
(will copy down once I have it working on the top row)
ok - makes no difference though and its NOT copied

="""countifs('prior period unbilled'!$E:$E, $I4, 'prior period unbilled'!$A:$A, $H4)>0"
why the ""
=countifs('prior period unbilled'!$E:$E, $I4, 'prior period unbilled'!$A:$A, $H4)>0

Highlight applicable range >>
A4:T10000 - Change, reduce or extend the rows to meet your data range of rows

Home Tab >> Styles >> Conditional Formatting
New Rule >> Use a formula to determine which cells to format
Edit the Rule Description: Format values where this formula is true:
=countifs('prior period unbilled'!$E:$E, $I4, 'prior period unbilled'!$A:$A, $H4)>0

Format [Number, Font, Border, Fill] - FILL YELLOW
choose the format you would like to apply when the condition is true
OK >> OK

I4 is trying to match to column E
and
H4 is trying to match to column A
if both match it highlights the row

then it moves down a row and checks again for row 5
 
Upvote 0
Solution

Forum statistics

Threads
1,215,110
Messages
6,123,147
Members
449,098
Latest member
Doanvanhieu

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