Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 18
Default Nested If Statements

Hi

I am trying to create the following formulae

=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(G7=-3,"Reminder","Available")))

Unfortunately G7 contains an if statement already based on other cells so my
answer is incorrect

Can anyone give me any advice as to what to do next please? PULLING MY HAIR
OUT!!!

Thanks

Sarah

Using MS Office Excel 2003, Sp2, Windows XP - Thanks again
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 563
Default Nested If Statements

It is unclear why your IF formula is noit working just because G7 contains a
formula. You tell us noithing about G7's formula. Could the problem be hat it
is returning a number which is formated? So for example iif might give -3.2
but displays -3. If this could be the problem try
=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(round(G7, 0) =-3 ,"Reminder",
"Available")))
best wishes
--
www.stfx.ca/people/bliengme


"Sarah_Lecturer" wrote:

Hi

I am trying to create the following formulae

=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(G7=-3,"Reminder","Available")))

Unfortunately G7 contains an if statement already based on other cells so my
answer is incorrect

Can anyone give me any advice as to what to do next please? PULLING MY HAIR
OUT!!!

Thanks

Sarah

Using MS Office Excel 2003, Sp2, Windows XP - Thanks again

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,646
Default Nested If Statements

Syntax of this formula is correct. Your question cannot be answered without
knowing the formula in G7 and content of cells it refers to. The best you can
do is to specify your data layout and aims for us!

Regards,
Stefi

€˛Sarah_Lecturer€¯ ezt Ć*rta:

Hi

I am trying to create the following formulae

=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(G7=-3,"Reminder","Available")))

Unfortunately G7 contains an if statement already based on other cells so my
answer is incorrect

Can anyone give me any advice as to what to do next please? PULLING MY HAIR
OUT!!!

Thanks

Sarah

Using MS Office Excel 2003, Sp2, Windows XP - Thanks again

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 18
Default Nested If Statements

Hi Bernard

I think I'm making this reply complicated, but I wanted to ensure I covered
all the wacky formulas I've inherited in this spreadsheet!

The formula in G7 is:

=IF(IF($C$2-F7<0,0,$C$2-F7)=$C$2," "," "&$C$2-F7)

Cell C2 is just an auto-update of today's date and F7 is a date pulled from
another tab, the formula in there is:

=IF('1'!$G$7=0,"0",'1'!$G$7)

A little convoluted perhaps (created by someone else!) but it's designed to
compare the F7 date against the current date and give a value of the
difference, which I'm then trying to create the H 'status' column on. An
example of what I'm finally trying to achieve is:

Column: COLUMN F COLUMN G COLUMN H
Heading: Date Due Back Days Over Due Status
Data: 25/3/2009 -8
Current
20/3/2009 -3
Reminder
0
Available
15/3/2009 2
Overdue


Essentially I am trying use the IF statement in column H (Status) to show if
the date due back is current (today or future), overdue (past date), time to
send a reminder (today - 3 days) or, if it's blank, to show available.

The IF formula in column H works for overdue and reminder, but puts both
current and available as simply current.

Hopefully that's clarified what I'm trying to do... or confused everyone
even more!

Thanks again for any help!
Sarah

"Bernard Liengme" wrote:

It is unclear why your IF formula is noit working just because G7 contains a
formula. You tell us noithing about G7's formula. Could the problem be hat it
is returning a number which is formated? So for example iif might give -3.2
but displays -3. If this could be the problem try
=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(round(G7, 0) =-3 ,"Reminder",
"Available")))
best wishes
--
www.stfx.ca/people/bliengme


"Sarah_Lecturer" wrote:

Hi

I am trying to create the following formulae

=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(G7=-3,"Reminder","Available")))

Unfortunately G7 contains an if statement already based on other cells so my
answer is incorrect

Can anyone give me any advice as to what to do next please? PULLING MY HAIR
OUT!!!

Thanks

Sarah

Using MS Office Excel 2003, Sp2, Windows XP - Thanks again

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 857
Default Nested If Statements

Hi,

Your results are not numbers but text, that is the problem. Concatenating a
space in front of a number converts it to text. If you want to create space
us indent or the alignment commands. If you must leave the space, thus text
than change your original formula

=IF(--TRIM(G7)=0,"Current",IF(--TRIM(G7)<0,"Overdue",IF(--TRIM(G7)=-3,"Reminder","Available")))

However, be advised that you formula is faulty. You text for <0 and then
you test for -3. If G7 is -3 it is also <0, so your last test is never
executed.

--
If this helps, please click the Yes button.

Cheers,
Shane Devenshire


"Sarah_Lecturer" wrote:

Hi Bernard

I think I'm making this reply complicated, but I wanted to ensure I covered
all the wacky formulas I've inherited in this spreadsheet!

The formula in G7 is:

=IF(IF($C$2-F7<0,0,$C$2-F7)=$C$2," "," "&$C$2-F7)

Cell C2 is just an auto-update of today's date and F7 is a date pulled from
another tab, the formula in there is:

=IF('1'!$G$7=0,"0",'1'!$G$7)

A little convoluted perhaps (created by someone else!) but it's designed to
compare the F7 date against the current date and give a value of the
difference, which I'm then trying to create the H 'status' column on. An
example of what I'm finally trying to achieve is:

Column: COLUMN F COLUMN G COLUMN H
Heading: Date Due Back Days Over Due Status
Data: 25/3/2009 -8
Current
20/3/2009 -3
Reminder
0
Available
15/3/2009 2
Overdue


Essentially I am trying use the IF statement in column H (Status) to show if
the date due back is current (today or future), overdue (past date), time to
send a reminder (today - 3 days) or, if it's blank, to show available.

The IF formula in column H works for overdue and reminder, but puts both
current and available as simply current.

Hopefully that's clarified what I'm trying to do... or confused everyone
even more!

Thanks again for any help!
Sarah

"Bernard Liengme" wrote:

It is unclear why your IF formula is noit working just because G7 contains a
formula. You tell us noithing about G7's formula. Could the problem be hat it
is returning a number which is formated? So for example iif might give -3.2
but displays -3. If this could be the problem try
=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(round(G7, 0) =-3 ,"Reminder",
"Available")))
best wishes
--
www.stfx.ca/people/bliengme


"Sarah_Lecturer" wrote:

Hi

I am trying to create the following formulae

=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(G7=-3,"Reminder","Available")))

Unfortunately G7 contains an if statement already based on other cells so my
answer is incorrect

Can anyone give me any advice as to what to do next please? PULLING MY HAIR
OUT!!!

Thanks

Sarah

Using MS Office Excel 2003, Sp2, Windows XP - Thanks again



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,766
Default Nested If Statements

Hi,

There is some problem in the logic. Since any number is =0 or <0, the
result will always toggle between "Current" and "Overdue". What exactly are
you trying to do?

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com

"Sarah_Lecturer" wrote in message
...
Hi

I am trying to create the following formulae

=IF(G7=0,"Current",IF(G7<0,"Overdue",IF(G7=-3,"Reminder","Available")))

Unfortunately G7 contains an if statement already based on other cells so
my
answer is incorrect

Can anyone give me any advice as to what to do next please? PULLING MY
HAIR
OUT!!!

Thanks

Sarah

Using MS Office Excel 2003, Sp2, Windows XP - Thanks again


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nested IF statements Valerie Excel Worksheet Functions 2 February 19th 09 03:36 AM
Nested IF statements using AND / OR Joe[_13_] Excel Worksheet Functions 2 February 9th 09 06:14 PM
Help with nested if/or statements Nick Excel Discussion (Misc queries) 8 September 14th 07 03:46 PM
Nested IF statements John Simons Excel Worksheet Functions 14 February 16th 05 06:17 AM
Do I need nested IF statements? Jaramya Excel Worksheet Functions 1 November 5th 04 09:10 PM


All times are GMT +1. The time now is 11:52 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"