+ Reply to Thread
Results 1 to 2 of 2

Using IF, Xlookup and Match/search, to find value in array.

  1. #1
    Registered User
    Join Date
    11-07-2018
    Location
    Sydney Australia
    MS-Off Ver
    2016 Pro
    Posts
    74

    Using IF, Xlookup and Match/search, to find value in array.

    Hi all,

    I have a seemingly easy one, but I just can't get my formula correct.

    I have a VBA Macro which needs to know what Australian States(and territory etc) are mentioned in an Array for each UserID

    e.g: UserID: might mention NSW and VIC in a single row array.

    I have a Cell for each State/territory for the Macro.

    What I need to do is LOOKUP a UserID and if NSW appears anywhere in the array (A4:P4) then return "NSW".

    I have attempted this a few ways and failed, happy to use VBA, but would like to use a formula if possible.

    My current attempt looks something like:

    Please Login or Register  to view this content.
    This spills the array into multiple cells. I know I need a match or search etc in there, but I just can't seem to land it. I tried IF(ISTEXT(SEARCH etc, but I can't get my nesting with XLOOKUP and IF correct.

    Thanks in advance
    Attached Images Attached Images

  2. #2
    Registered User
    Join Date
    11-07-2018
    Location
    Sydney Australia
    MS-Off Ver
    2016 Pro
    Posts
    74

    Re: Using IF, Xlookup and Match/search, to find value in array.

    All good, solved it myself:

    =IF(IFERROR(FIND("NSW",XLOOKUP(..........),1),"")<>"","NSW","")

+ 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. Replies: 14
    Last Post: 09-28-2019, 10:32 PM
  2. Text search function, array, lookup, match
    By Kollasch40 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-05-2016, 10:45 AM
  3. FIND/SEARCH Formula Using an Array
    By ASPENCO in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 03-12-2016, 04:39 PM
  4. Replies: 6
    Last Post: 09-03-2015, 09:51 PM
  5. [SOLVED] Array Find or Array Search
    By dluhut in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-15-2014, 03:03 PM
  6. [SOLVED] Find Data in one array and match the position in another array
    By zeeman2 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-27-2013, 07:55 PM
  7. SEARCH and MATCH with array list
    By kolokor in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-13-2011, 03:41 PM

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