+ Reply to Thread
Results 1 to 9 of 9

macro or formula needed for matching criteria

  1. #1
    Forum Contributor
    Join Date
    11-16-2014
    Location
    United States
    MS-Off Ver
    2010
    Posts
    204

    macro or formula needed for matching criteria

    Hi Champs,

    I have a record set from col A to col E

    Doc #, Code, Account, Description and amount.

    i need a macro or function to display all the line items of the doc # (A col) with code 40 or 50 (B col) with amount in 5 series (starting with 5) in Ccolumn.

    that is if doc # has code 40 or 50 with 5 series account all the line items of the respective doc # has to be displayed. I have attached the sample.

    pls help.sample.xlsx

  2. #2
    Forum Contributor
    Join Date
    03-11-2014
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    379

    Re: macro or formula needed for matching criteria

    Hi,

    May be this will help you.

    Regards,
    AM

  3. #3
    Forum Contributor
    Join Date
    03-11-2014
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    379

    Re: macro or formula needed for matching criteria

    Hi,

    In Range A4:E31 try the
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    in CF.

    Regards,
    AM

  4. #4
    Forum Contributor
    Join Date
    09-05-2012
    Location
    Dubai
    MS-Off Ver
    Office 365
    Posts
    409

    Re: macro or formula needed for matching criteria

    You want Macro to provide your result for input ? or Output also ?

    Below will work for Phase 1 which is input...

    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    11-16-2014
    Location
    United States
    MS-Off Ver
    2010
    Posts
    204

    Re: macro or formula needed for matching criteria

    Hi Asishmehra 2010,


    Your formula pulls the record of code 40 and 50 only, but if the doc has 40 or 50 with 5 series, all other codes should also be displayed as in my sample file. Pls help

  6. #6
    Forum Contributor
    Join Date
    03-11-2014
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    379

    Re: macro or formula needed for matching criteria

    Hi,

    I have tried using Conditional Formatting which is matching with the Output that you have provided in the initial post.
    Refer to sheet CF.

    Regards,
    AM

  7. #7
    Forum Contributor
    Join Date
    11-16-2014
    Location
    United States
    MS-Off Ver
    2010
    Posts
    204

    Re: macro or formula needed for matching criteria

    yes conditional formatting is perfect... but i need to display only the matched record and not the other ones. iif i get my input and run the macro or formula, the output mentioned in my sample has to be displayed. pls help

  8. #8
    Forum Contributor
    Join Date
    09-05-2012
    Location
    Dubai
    MS-Off Ver
    Office 365
    Posts
    409

    Re: macro or formula needed for matching criteria

    Check attached...
    Attached Files Attached Files

  9. #9
    Forum Contributor
    Join Date
    03-11-2014
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    379

    Re: macro or formula needed for matching criteria

    Hi,

    Unfortunately your statement contradicts.
    Post#7: I need to display only the matched record and not the other ones.
    Ans: Refer to file attached in post#2

    Q: If I search for greater than equal to 40 or less than equal to 50 in Code column then which rows would you like to skip.
    Please define the logic.

    Regards,
    AM

  10. #10
    Forum Contributor
    Join Date
    03-11-2014
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    379

    Re: macro or formula needed for matching criteria

    Quote Originally Posted by naveenmarapaka View Post
    Check attached...
    Hi Naveen,

    Thanks for sharing file, the code is working fine. Clean(C1) does the trick.

    I learned something new from you.

    Regards,
    AM

+ 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. Data matching formula needed!
    By Rohan in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 01-21-2014, 11:25 AM
  2. [SOLVED] VBA / Macro help needed for matching partial text string
    By krjoshi in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-21-2013, 09:41 PM
  3. Replies: 2
    Last Post: 02-04-2013, 05:48 PM
  4. [SOLVED] Urgent help needed on multiple criteria matching
    By kalyanaasuri in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-07-2012, 05:05 PM
  5. Field matching formula help needed.
    By andysmith in forum Excel General
    Replies: 11
    Last Post: 05-13-2009, 07:58 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