+ Reply to Thread
Results 1 to 26 of 26

x_fin nested if

  1. #1
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    x_fin nested if

    Hi ,
    I have been provided a file, which has latest version, but i am using 2010.. So i am getting #name error and the formula ifs are converted to xlfin .. the row lines go to 3000.. is there any code for changing this xlfin to normal ifs... i tried changing for every cell, it is tiring as the formulas are different..

  2. #2
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: x_fin nested if

    IFS will not work with 2010, so I think that you need to go to nested IFs. To replace in mass, just select the range and Ctrl+H, first box xlfin, second one ifs, replace all.
    Click the * to say thanks.

  3. #3
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486
    Quote Originally Posted by PaulM100 View Post
    IFS will not work with 2010, so I think that you need to go to nested IFs. To replace in mass, just select the range and Ctrl+H, first box xlfin, second one ifs, replace all.
    Hi,
    It is giving #name

  4. #4
    Forum Expert PaulM100's Avatar
    Join Date
    10-09-2017
    Location
    UK
    MS-Off Ver
    Office 365
    Posts
    2,108

    Re: x_fin nested if

    That is what I was trying to say. It wont work. So instead of IFs you will need to change it to IF(IF(IF. This is just an example. More on nested IFs: https://exceljet.net/formula/nested-if-function-example

  5. #5
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    but how to do it for 2 sheets fully.. Is there any array function that can be created and used..
    Doing each cell, i would complete after 30 days..

  6. #6
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    I tried to create a function using left,mid to insert if.. but that goes haywire... not working..

  7. #7
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    I'm not sure I can help but can you post some examples of the formula and also the result as expected?

  8. #8
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,446

    Re: x_fin nested if

    Welcome to the forum

    Please attach a sample workbook (not a picture or pasted copy). Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.

  9. #9
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi Akuini,
    +_xlfn.IFS(D24=0,0,D24=1,+'account_type_transactions (2)'!AD19*E24,D24=2,+'account_type_transactions (2)'!AD19*E24+'account_type_transactions (2)'!AE19*E24)
    +_xlfn.IFS(D24=0,0,D24=1,+'account_type_transactions (2)'!AD19*E24,D24=2,+'account_type_transactions (2)'!AD19*E24+'account_type_transactions (2)'!AE19*E24,D24=3,'account_type_transactions (2)'!AD19*E24+'account_type_transactions (2)'!AE19*E24+'account_type_transactions (2)'!AF19*E24)

    some of the formulas, here you can see all formulas have different nested if count, so i am not understanding how to go about this...

    Hi Mokko,
    I dont know, why but the file is being upload failed.. Initially it was over mb and i compressed it, both failed.. I even tried to upload the sheet saved to another.. but keep failing..
    i am not getting what is the issue..

  10. #10
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    Please show us the expected results of those examples.

  11. #11
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi,
    it is a nested if function, due to which when working below excel 2016 , it creates a x_fin at the begining..

    So the correct formula for 2007/10/13 excel be like if(d24=0,0,if(d24=1,sheetname ad19*e24,if(d24=2.....
    it goes on like this..
    So in latest version this is replaced by IFS function, which is not available in older version. So i get X_fin at the beginning..
    This i want to change to if(..if( as mentioned above..
    is there any chance..

    i tried capturing comma and after comma to insert.. But this always not give correct answer.. Manually changing is also not possible. Two sheets of 200 rows exist..
    Any idea

  12. #12
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    Is it possible that your formula with IFS is just a part of more complex formula?
    If the IFS formula is the whole formula and there is only 1 IFS, let's try this:
    1. select 1 cell that has formula with IFS
    2. run this code

    see if works as expected, if it does then:
    - I can amend the code so you can select multiple cells at once
    - and we can explore how to deal with more complex formula.

    Note: At the moment I put the result only in the immediate window, so you won't see any changes in the cell formula yet.

    Please Login or Register  to view this content.

    Result in Immediate Window:

    Please Login or Register  to view this content.

  13. #13
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,446

    Re: x_fin nested if

    Quote Originally Posted by dorabajji View Post

    Hi Mokko,
    I dont know, why but the file is being upload failed.. Initially it was over mb and i compressed it, both failed.. I even tried to upload the sheet saved to another.. but keep failing..
    i am not getting what is the issue..
    You can zip the file and upload it. It would help members help you
    Follow the instructions in my post . Do NOT use the paperclip

  14. #14
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    Sorry, forgot to replace "_xlfn.IFS" with "IF", use this one:

    Please Login or Register  to view this content.

  15. #15
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi,
    It was too good.. I tested 5 formulas.. it gives correct result.. Can this be applied to whole sheet(row lines 200) and column till AA).. Can you modify and provide me?
    as my array knowledge is not that good, i would appreciate if you could modify..

    your logic was good, where as i was struggling with string functions.. I had splitted using "," but then was struck..


    Thank you for your efforts..

    And one more thing..
    IF(SUM(Z22:CH22)=0,0,_xlfn.IFS(CL22=0,xxxxxx
    If the formula comes like this in above , then i need one condition more.. the replacement should happen after xlfn.ifs.. not before that, as first one is already if.

    in the immediate window for the above comes like this..
    =IF(SUM(AC22:CH22)=0,0,IF(IF(CO22=0,xxxxxxx

    So here for xlfn if is taken and after , so another if is taken..
    other than this , for whatever i checked it works completely fine..


    Please Login or Register  to view this content.
    in the above code.. before replacing, check if is already there if there only remove xlfn..else the same to be continued.
    Last edited by dorabajji; 10-18-2019 at 03:50 PM.

  16. #16
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    OK, try tyhis:
    Select the range then run "Sub IFS_to_IF":


    Please Login or Register  to view this content.

  17. #17
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi Akuini,
    This is what i expected thank you.
    I want to know, for if this is perfect. I dont have in my file anyother than if.. But there are other functions too upgraded in latest like max, min..
    in that case you will get xlfn_max , so one has to change to max(if..(if .. In that case how to do it.

  18. #18
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    But there are other functions too upgraded in latest like max, min..
    in that case you will get xlfn_max , so one has to change to max(if..(if .. In that case how to do it.
    I'm not sure I can amend the code to do that, but can you give me some clear & simple examples and also the result as expected?

  19. #19
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,720

    Re: x_fin nested if

    I think he means MAXIF and MAXIFS.

    You might end up doing one for CONCAT and TEXTJOIN ...

    Pete

  20. #20
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi Akuini,
    This is the formula
    xlfn_max (D3:D15,C3:C15,"Finance")


    Hi Pete,
    Yes, in excel 2010 when i get latest version files, i have this xlfn issue.. So have to rechange full sheet.
    Thats Y..

  21. #21
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    So it's only xlfn_max not xlfn_maxifs? what is the expected result?
    Are there other functions besides xlfn_max? If yes, give us examples of each & also the results as expected.

  22. #22
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi Akuini,
    no i was wrong.. _xlfn.MaxIFS ... not max..
    I dont know how to incorporate into lower version.. But the output is if the word finance in col C range then find max of col D range..
    How to convert this to excel 2010.. I am not sure.. Do you have any idea..

  23. #23
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,647

    Re: x_fin nested if

    Try this:

    =MAX(IF(C3:C15="Finance",D3:D15))

    ... confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  24. #24
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    How to convert this to excel 2010.. I am not sure.. Do you have any idea..
    My knowledge of excel formula is very basic, so I don't know how.
    But it would help if you can attach your file.
    To attach a file:
    In the reply box click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    (Don’t use the paper clip icon to attach your file, it doesn’t work.)

    Note: I can see AliGW has provided you an answer, so maybe you can show some other formula examples (maybe more complex ones), so she or someone else can help you.

  25. #25
    Forum Contributor
    Join Date
    07-10-2019
    Location
    england
    MS-Off Ver
    2013
    Posts
    486

    Re: x_fin nested if

    Hi Akuini,
    If the AliGW's array formula is used, then how to change the cells. Previously we needed to add, only if, but right now it is totally different to the original formula?
    I am trying to find any file in my office has this kind of formula, i dont have in my file. But i want to make sure, if i get again like this, to be more prepared. As the previous was very useful to change .. with this output and the previous formula sample, is it possible to change using macro?

  26. #26
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: x_fin nested if

    Well, it's possible to do it with macro, but depends on the complexity it maybe hard to code.
    It would be better to wait until you have the files in question, then you can start a new thread to post the new formulas problem.

    And if the solution offered here so far answers your original question, then you can mark this thread as solved.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Trying to Convert Excel nested IF to Access nested IIF
    By bbeards in forum Access Tables & Databases
    Replies: 5
    Last Post: 10-10-2018, 10:33 PM
  2. [SOLVED] Nested IF and nested Concatenation formula
    By VisionSmart in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 10-09-2018, 08:00 AM
  3. [SOLVED] Nested vlookup or nested IFAND function?
    By jeptik in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 03-11-2017, 02:27 AM
  4. Easier Way To Decipher Nested Nested IF's
    By Vladamir in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-06-2015, 03:37 PM
  5. [SOLVED] Nested Sumif's or how to sum data based on nested criteria
    By dlietz in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 10-07-2014, 11:36 AM
  6. How to reduces Nested IF code(144 Nested IF) to achive same functionality
    By jobseeker in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-09-2014, 09:45 AM
  7. help on a nested countif/nested if formula
    By vickiemc in forum Excel General
    Replies: 2
    Last Post: 08-13-2008, 08:29 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1