Hello,
Trying to make this nested statement work getting ERR 508 (Pair Missing) Any Help would be appreciated
=IF (C33=1;735;0,IF (C34=1;1200;0,IF (C35=1;1500;0,IF (C36=1;1800;0,IF (C37=1;2200;0)))))
the If(C33=true keeps changing to a 1) not sure how to fix that. This is putting the value in a cell when a check box in ticked (normal check box empty = false when, checked it changes to true and applies the value)
[Solved] Nested IF() Statement
-
- Posts: 1
- Joined: Sun Aug 01, 2021 6:47 pm
[Solved] Nested IF() Statement
Last edited by MrProgrammer on Mon Aug 09, 2021 4:02 pm, edited 1 time in total.
Reason: Tagged ✓ [Solved]
Reason: Tagged ✓ [Solved]
Apache OpenOffice 4.1.10
Re: Nested IF() Statement
The structure of the IF functions is wrong. Try
TRUE has a value of 1. You can use them interchangeably.
Code: Select all
=IF(C33=1;735;IF(C34=1;1200;IF(C35=1;1500;IF(C36=1;1800;IF(C37=1;2200;0)))))
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
Re: Nested IF() Statement
=INDEX({735;1200;1500;1800;2200};MATCH(1;$C$33:$C$37;0))
or put the 5 numbers in some cell range, say x1:x5, and
=INDEX($X$1:$X$5;MATCH(1;$C$33:$C$37;0))
or put the 5 numbers in some cell range, say x1:x5, and
=INDEX($X$1:$X$5;MATCH(1;$C$33:$C$37;0))
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
- MrProgrammer
- Moderator
- Posts: 4908
- Joined: Fri Jun 04, 2010 7:57 pm
- Location: Wisconsin, USA
Re: Nested IF() Statement
IF is a function. Calc doesn't have any statements.TargetDummy wrote:Nested IF() Statement
=IF(SUMPRODUCT(C33:C37=1);CHOOSE(MATCH(1;C33:C37;0);735;1200;1500;1800;2200);0)TargetDummy wrote:=IF (C33=1;735;0,IF (C34=1;1200;0,IF (C35=1;1500;0,IF (C36=1;1800;0,IF (C37=1;2200;0)))))
CHOOSE function
MATCH function
[Tutorial] The SUMPRODUCT function
Of course, since your use of the IF function is bogus. Do not guess at syntax. You can't chain IF functions together with commas!TargetDummy wrote:Trying to make this nested statement work getting ERR 508 (Pair Missing)
If you need any additional assistance attach a document demonstrating the difficulty (remove confidential information then use Post Reply, not Quick Reply, and don't attach a picture instead of the document itself).
If this solved your problem please go to your first post use the Edit button and add [Solved] to the start of the subject field. Select the green checkmark icon at the same time.
[Tutorial] Ten concepts that every Calc user should know
Mr. Programmer
AOO 4.1.7 Build 9800, MacOS 13.6.3, iMac Intel. The locale for any menus or Calc formulas in my posts is English (USA).
AOO 4.1.7 Build 9800, MacOS 13.6.3, iMac Intel. The locale for any menus or Calc formulas in my posts is English (USA).