+ Reply to Thread
Results 1 to 9 of 9

VBA find row for double conditions

  1. #1
    Registered User
    Join Date
    05-08-2017
    Location
    Paris
    MS-Off Ver
    2013
    Posts
    35

    VBA find row for double conditions

    Dear all,

    I would once again really appreciate your help on the following below:

    I need to find the row number when two conditions are met:

    1. First, find in column 23 the value x
    2. Second, find in column 91 the value shop

    Wheb I run the code, it doesnt work yet. Do you have any tips?

    Thanks!!

    Please Login or Register  to view this content.
    Last edited by jeffreybrown; 02-17-2018 at 06:51 PM. Reason: Please use code tags!

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,920

    Re: VBA find row for double conditions

    I am not quite sure of the requirement, but this code will find where "x" is found in column 23, and then starting at that row, look for "shop" in column 91.
    Please Login or Register  to view this content.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Forum Contributor
    Join Date
    01-03-2018
    Location
    Fukuoka, Japan
    MS-Off Ver
    Excel 2013
    Posts
    123

    Re: VBA find row for double conditions

    I guess Bundi wants the row where column 23 has "x" and column 91 has "shop".
    Then, try the code below.

    Please Login or Register  to view this content.

  4. #4
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,525

    Re: VBA find row for double conditions

    Try
    Please Login or Register  to view this content.
    Last edited by jindon; 02-18-2018 at 01:45 AM.

  5. #5
    Registered User
    Join Date
    05-08-2017
    Location
    Paris
    MS-Off Ver
    2013
    Posts
    35

    Re: VBA find row for double conditions

    yujin, your code works great! THank you all for your help!

  6. #6
    Forum Contributor
    Join Date
    01-03-2018
    Location
    Fukuoka, Japan
    MS-Off Ver
    Excel 2013
    Posts
    123

    Re: VBA find row for double conditions

    You are welcome, Bundi. Thank you for your feedback.
    Personally, jindon's code, using an array, interests me.

  7. #7
    Registered User
    Join Date
    05-08-2017
    Location
    Paris
    MS-Off Ver
    2013
    Posts
    35

    Re: VBA find row for double conditions

    Dear Jindon,

    Indeed, your code works superfast with the same principle, very smart indeed.

    I just have one stupid question; iso returning a message box with the line row, can a just be assigned with the row found and stop therafter?

    Thanks!!!!!

  8. #8
    Registered User
    Join Date
    05-08-2017
    Location
    Paris
    MS-Off Ver
    2013
    Posts
    35

    Re: VBA find row for double conditions

    Your help would be highly appreciated!

  9. #9
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,525

    Re: VBA find row for double conditions

    You mean like this?
    Please Login or Register  to view this content.

+ 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. Double if conditions to match then add to an existing dictionary
    By KAYABRFR in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-11-2018, 11:48 AM
  2. selection on double conditions
    By petenc in forum Excel General
    Replies: 2
    Last Post: 05-12-2017, 03:26 PM
  3. [SOLVED] Using find replace to first find two double quotes and replace with a single double quote
    By welchs101 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-17-2015, 10:13 AM
  4. Replies: 0
    Last Post: 08-26-2014, 08:04 AM
  5. [SOLVED] Double find?
    By PyhaWaim in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-21-2014, 10:49 AM
  6. Change cells back to original conditions by double clicking another cell
    By Bonnister in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-14-2013, 10:21 AM
  7. [SOLVED] double conditions for CountIf
    By Knud Gentz in forum Excel General
    Replies: 3
    Last Post: 04-03-2005, 06:06 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