+ Reply to Thread
Results 1 to 5 of 5

MATCH using Multiple Criteria and Return the Row Numbers

  1. #1
    Registered User
    Join Date
    09-08-2013
    Location
    London, England
    MS-Off Ver
    Excel 2003
    Posts
    2

    MATCH using Multiple Criteria and Return the Row Numbers

    Hey,

    I'm relatively new to Excel and I'm currently trying to use it as a sort of database (as restricted access to other programs). I'm use to computer programming so I'll try explain it in those terms.

    I have a worksheet of data, I want to search that worksheet of data using VBA for ALL rows which have XthisX in column B and XthatX in column D and return the ROW numbers. I then want to LOOP through the row numbers and format the data myself programmatically.

    Any help on this matter would be very much appreciated.

    -Vince

  2. #2
    Forum Expert
    Join Date
    05-30-2012
    Location
    The Netherlands
    MS-Off Ver
    Office 365
    Posts
    14,987

    Re: MATCH using Multiple Criteria and Return the Row Numbers

    You get better and quicker result on your question if you follow the advice below.

    http://www.excelforum.com/the-water-...-question.html
    Notice my main language is not English.

    I appreciate it, if you reply on my solution.

    If you are satisfied with the solution, please mark the question solved.

    You can add reputation by clicking on the star * add reputation.

  3. #3
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 2019 on Win10 (desktop), 2019 on Win11 (notebook)
    Posts
    8,197

    Re: MATCH using Multiple Criteria and Return the Row Numbers

    Hi, Vince,

    uer the Autofilter first on Column B and after that on Column D. Then check if any rows are visible as a result, build a range on the visible cells and then loop through them (here the address is written to the Immediate Window):

    Please Login or Register  to view this content.
    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  4. #4
    Registered User
    Join Date
    09-08-2013
    Location
    London, England
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: MATCH using Multiple Criteria and Return the Row Numbers

    performance_tracker.xlsm

    Thanks for the reply Hahobe.

    I'm afraid I'm not doing too well comprehending VBA.... :/

    Please Login or Register  to view this content.
    The above code filters correctly however, the range address shows $A$2. I figured it would just be a case of looping through the rows and pointing to the using I.E Range(LOOPED_NUM,"A").Value and so on. I guess it's not that simple right?

    Forgive my inability to comprehend your answer, I try too hard to run before I can walk.

  5. #5
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 2019 on Win10 (desktop), 2019 on Win11 (notebook)
    Posts
    8,197

    Re: MATCH using Multiple Criteria and Return the Row Numbers

    Hi, biosonik,

    maybe this can help. I added Results to Sheet Result in Range("A8") and deleted A9 there:
    Please Login or Register  to view this content.
    Ciao,
    Holger

+ 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 match multiple criteria and return a corresponding value
    By consulttk in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 11-30-2012, 04:07 PM
  2. [SOLVED] match multiple criteria & return value from array
    By Peo Sjoblom in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-06-2005, 07:05 AM
  3. match multiple criteria & return value from array
    By Peo Sjoblom in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-06-2005, 04:05 AM

Tags for this Thread

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