Nested if statement or an array formula

Mel Smith

Well-known Member
Joined
Dec 13, 2005
Messages
1,023
Office Version
  1. 365
Platform
  1. Windows
I have to set up a tracking spreadsheet and I'm trying to work out a formula for the following:

In cell P1:

1. If Cell C1 and Cell L1 are blank, then P1 is blank
2. If Cell C1 is not blank and L1 is blank, then P1 displays "Error"
3. If Cell C1 is blank and L1 is not blank, P1 dispalys "Error"

Any help or suggestions would be most appreciated.

Thanks.
 

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.
Copy following formula in P1:
=IF(AND(ISBLANK(c1);ISBLANK(l1)),"","error")
 
Upvote 0
Hello all,
I think I am in the right area and hope you can help. I am trying to get the below formula to only calculate a cell that contains a number. I tries to use the if is blank function, but keep getting errors.

=IF(Antigens!$H37<Antigens!$J37,Antigens!$N37,Antigens!$M37)

Basically I want this formula to only return a result if there is a number in H37. If H37 is blank then the result should be blank. If anyone could help, I would really appreciate it.

Regards,

Paul
 
Upvote 0
Hello all,
I think I am in the right area and hope you can help. I am trying to get the below formula to only calculate a cell that contains a number. I tries to use the if is blank function, but keep getting errors.

<antigens!$j37,antigens!$n37,antigens!$m37)
=IF(Antigens!$H37<Antigens!$J37,Antigens!$N37,Antigens!$M37)

Basically I want this formula to only return a result if there is a number in H37. If H37 is blank then the result should be blank. If anyone could help, I would really appreciate it.

Regards,

Paul</antigens!$j37,antigens!$n37,antigens!$m37)
 
Upvote 0
Hi,

Perhaps you should explain in detail what exactly you want the formula to do...like....if H37 is a number, then result (what result?)

=IF(ISNUMBER(Antigens!$H37),"Your Result Here","")
 
Upvote 0
Hi,

Perhaps you should explain in detail what exactly you want the formula to do...like....if H37 is a number, then result (what result?)

=IF(ISNUMBER(Antigens!$H37),"Your Result Here","")

Hi jtakw,

I apologize, not all of my formula appeared in my original question. So what I am trying to do is build a purchase requisition for my job. All the cells in column H will initially be blank, when the user populates the cell with a number my formula (see below) will put the result in the cell in column P.

=IF(Antigens!$H15<Antigens!$J15,Antigens!$N15,Antigens!$M15)

If column H is blank then I would like column P to be blank too.
 
Upvote 0
Hi jtakw,

I apologize, not all of my formula appeared in my original question. So what I am trying to do is build a purchase requisition for my job. All the cells in column H will initially be blank, when the user populates the cell with a number my formula (see below) will put the result in the cell in column P.

=IF(Antigens!$H15< Antigens!$J15,Antigens!$N15,Antigens!$M15)

If column H is blank then I would like column P to be blank too.

Where in your formula do you refer to Column P???

And What's in Column J, N and M???
 
Last edited:
Upvote 0
Hi jtakw,
First of all thank you for your patience, I am relatively new to this forum. What I am trying to do is make a purchase requisition so all the user has to do is enter in the quantity on hand and the order quantity will populate based on the clinics Par level. I have 5 column/cells that I am working with;

Count (H26) user inserts quantity on hand here
PAR (J26) Minimum quantity the clinic should have on hand
VAR1 (M26) Calculates/Converts to minimum order quantity (Each to Box or Case)
VAR2 (N26) Calculates/Converts to order minimum quantity (ML to Bottles)
Order QTY (P26) Total quantity to order based on formula =IF(Antigens!$H26<Antigens!$J26,Antigens!$N26,Antigens!$M26)

What I am after is that when column H26 is left blank Column P26 is blank as well. When H26 has a number P26 populates the order quantity based on N26 and M26. I think your idea of IFISNUMBER is the right track but cant get it to work. This is what I tried;
=IFH26(ISNUMBER(Antigens!$H26<Antigens!$J29,Antigens!$N26,Antigens!$M26),””,))

Thank you again jtakw!
 
Upvote 0

Forum statistics

Threads
1,214,979
Messages
6,122,552
Members
449,088
Latest member
davidcom

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