+ Reply to Thread
Results 1 to 9 of 9

Multiple IF-s, or VLOOKUP

  1. #1
    Registered User
    Join Date
    08-14-2020
    Location
    Croatia, Slavonski brod
    MS-Off Ver
    Microsoft office 365 ProPlus
    Posts
    10

    Multiple IF-s, or VLOOKUP

    Hi all!

    Im new to this forum, so please forgive me if i posted in wrong section.

    I have a problem, and ive been trying to find solution, but barely with any success (i am using Office 365ProPlus version).

    - with my limited skills, i am trying to have one main column, which cell will gather data on multiple other columns cells and ,depending if those columns are blank, or have anything in cell, display text.

    So, for example:

    * Cell A1 will give 3 possible texts (Send to department1, Send to department2, Send to department3)
    * Send to department1 will be displayed if B1 cell has anything, wont be displayed if cell is blank
    * Send to department2 will be displayed if C1 cell has anything, wont be displayed if cell is blank
    * Send to department2 will be displayed if D1 cell has anything, wont be displayed if cell is blank

    * Text priority should be determinated to the right, so if both B1 and C1 cells have anything, then Send to department2 should be displayed while Send to department1 should be ignored...etc with further cells

    So far, i am able to display one text depending on one cell, but i am not able to do this with multiple cells.

    This is my current formula:

    =IF(B1<>"";"Send to department1";"")

    Please note that i use ;
    My formulas are not working with ,

    If any help or advice is given, i would really appreciate it. Thanks!

  2. #2
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,657

    Re: Multiple IF-s, or VLOOKUP

    May be:
    Please Login or Register  to view this content.
    Quang PT

  3. #3
    Registered User
    Join Date
    08-14-2020
    Location
    Croatia, Slavonski brod
    MS-Off Ver
    Microsoft office 365 ProPlus
    Posts
    10

    Re: Multiple IF-s, or VLOOKUP

    Quote Originally Posted by bebo021999 View Post
    May be:
    Please Login or Register  to view this content.
    Thank you for your quick answer, however, it didnt work.
    Check attachment please, i have made an excel example of what im using and what i need.

    Cell A1 will contain Text, while C1 and F1 will have data or be blank. If they have data, text in A1will be displayed, if blank, then text in A1 wont be displayed.

    Also, with priority of cells to the right.
    Attached Files Attached Files

  4. #4
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,657

    Re: Multiple IF-s, or VLOOKUP

    Quite different issue.
    Anyway, try:
    =IF(SUMPRODUCT(LEN(C1:F1))=0,"","Department1")

  5. #5
    Registered User
    Join Date
    08-14-2020
    Location
    Croatia, Slavonski brod
    MS-Off Ver
    Microsoft office 365 ProPlus
    Posts
    10

    Re: Multiple IF-s, or VLOOKUP

    This also didnt work.

    Text "Department1" didnt depend on data in cell C1, and there is no text "Department2" which depends on data in cell F1.

    (when i removed data from those cells, A1 is not changed, it says "Department1" whatever i do).

    I also dont want data between cells D and E to be used, just C1 and F1.
    Last edited by Dado87; 08-14-2020 at 06:32 AM.

  6. #6
    Forum Contributor
    Join Date
    06-30-2015
    Location
    Netherlands
    MS-Off Ver
    2013 / 2016 / 365
    Posts
    146

    Re: Multiple IF-s, or VLOOKUP

    Hi,

    We don't mind you being new to the forum however it's hard to help if the question changes.

    Your initial question was:
    * Cell A1 will give 3 possible texts (Send to department1, Send to department2, Send to department3)
    * Send to department1 will be displayed if B1 cell has anything, wont be displayed if cell is blank
    * Send to department2 will be displayed if C1 cell has anything, wont be displayed if cell is blank
    * Send to department2 will be displayed if D1 cell has anything, wont be displayed if cell is blank
    * Text priority should be determinated to the right, so if both B1 and C1 cells have anything, then Send to department2 should be displayed while Send to department1 should be ignored.

    Just notice there's no criteria relating to filling Cell A1 with the text "Send to department3"

    Going forward from that:
    this formula states exactly what's asked for in the question.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    This is an Array formula so should be entered by combining Ctrl+Shift+Enter.
    HtH,

    Joris

    --------------------------------------------------------------------------------
    If you found my answer helpful, please hit the Like or Thank button.

    Please follow the forum Rules and Guidelines and use Code tags around your VBA code.

    Remember: test VBA code always on a copy of your file because usually you can't use undo

  7. #7
    Registered User
    Join Date
    08-14-2020
    Location
    Croatia, Slavonski brod
    MS-Off Ver
    Microsoft office 365 ProPlus
    Posts
    10

    Re: Multiple IF-s, or VLOOKUP

    Quote Originally Posted by joris moerings View Post
    Hi,

    We don't mind you being new to the forum however it's hard to help if the question changes.

    Your initial question was:
    * Cell A1 will give 3 possible texts (Send to department1, Send to department2, Send to department3)
    * Send to department1 will be displayed if B1 cell has anything, wont be displayed if cell is blank
    * Send to department2 will be displayed if C1 cell has anything, wont be displayed if cell is blank
    * Send to department2 will be displayed if D1 cell has anything, wont be displayed if cell is blank
    * Text priority should be determinated to the right, so if both B1 and C1 cells have anything, then Send to department2 should be displayed while Send to department1 should be ignored.

    Just notice there's no criteria relating to filling Cell A1 with the text "Send to department3"

    Going forward from that:
    this formula states exactly what's asked for in the question.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    This is an Array formula so should be entered by combining Ctrl+Shift+Enter.
    Im sorry, maybe i didnt define the question very best.

    Could you please try to edit Example excel file which i attached above?

    - 3 cells are used for this, A1, C1, and F1
    - if C1 and F1 dont have any value (date, number, letter) then A1 will be blank
    - if C1 has any value, but F1 doesnt have, A1 will display text "Department1"
    Attachment 690973
    - if F1 has any value, but C1 doesnt have, A1 will display text "Department2"
    Attachment 690974
    - if both C1 and F1 have any value, A1 will display text "Department2" because i want that F1 has priority over C1
    Attachment 690976

    Cells between, like B1, D1, E1 will contain another data so i dont want them to be used in formula.

  8. #8
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,657

    Re: Multiple IF-s, or VLOOKUP

    Try in A1:
    =IF(F1<>"","Department2",IF(C1<>"","Department1",""))

  9. #9
    Registered User
    Join Date
    08-14-2020
    Location
    Croatia, Slavonski brod
    MS-Off Ver
    Microsoft office 365 ProPlus
    Posts
    10

    Re: Multiple IF-s, or VLOOKUP

    Quote Originally Posted by bebo021999 View Post
    Try in A1:
    =IF(F1<>"","Department2",IF(C1<>"","Department1",""))
    Thank you, this works on my home pc!
    Now i cant wait till monday to try it at work

+ 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. [SOLVED] VLOOKUP with multiple conditions or multiple VLOOKUP?
    By Grizraz in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-23-2019, 02:55 AM
  2. Replies: 5
    Last Post: 05-27-2019, 03:46 PM
  3. Vlookup Formula to update multiple exchange rates for multiple products
    By jocpatch in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-24-2016, 08:36 PM
  4. Help using vlookup to return multiple results for one vlookup value
    By Akmon in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 02-27-2015, 06:00 AM
  5. [SOLVED] VLookup - Single value lookup returning multiple records into multiple columns
    By kllovin in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 02-07-2014, 05:14 AM
  6. Replies: 3
    Last Post: 07-25-2013, 08:25 AM
  7. vlookup? match? index? MULTIPLE criteria for vlookup search problem....
    By aborg88 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 02-11-2013, 09:56 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