+ Reply to Thread
Results 1 to 5 of 5

VBA Macro to create a unique list of dimensions and maximum value

  1. #1
    Registered User
    Join Date
    03-01-2020
    Location
    Paris
    MS-Off Ver
    Office 2016
    Posts
    28

    VBA Macro to create a unique list of dimensions and maximum value

    Hello All,

    I have a simple dataset with 'Category' and different product under each of those category and the quantity of product sold under each of these category.

    I would like to have your help in creating a macro which can read the dataset and list all the unique category along with the product that has been sold the most under each of these categories.

    I have attached the excel for reference.

    Thanks

  2. #2
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: VBA Macro to create a unique list of dimensions and maximum value

    Formula for H13 =INDEX($A$5:$C$15,SUMPRODUCT(MATCH(MAX(($A$5:$A$15=G13)*$C$5:$C$15),--($A$5:$A$15=G13)*$C$5:$C$15,0)),2)
    My General Rules if you want my help. Not aimed at any person in particular:

    1. Please Make Requests not demands, none of us get paid here.

    2. Check back on your post regularly. I will not return to a post after 4 days.
    If it is not important to you then it definitely is not important to me.

  3. #3
    Registered User
    Join Date
    03-01-2020
    Location
    Paris
    MS-Off Ver
    Office 2016
    Posts
    28

    Re: VBA Macro to create a unique list of dimensions and maximum value

    The solution helps, however I am looking to do this in VBA.

    Excel formulla may be the best and efficient solution, however the code suggestion requested is part of a vba program which I am trying to build

  4. #4
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: VBA Macro to create a unique list of dimensions and maximum value

    And your Macro can Enter that formula in cells in Range H13, or in any other range. Where is the issue?

    Please Login or Register  to view this content.
    Last edited by mehmetcik; 03-11-2020 at 04:12 PM.

  5. #5
    Registered User
    Join Date
    03-01-2020
    Location
    Paris
    MS-Off Ver
    Office 2016
    Posts
    28

    Re: VBA Macro to create a unique list of dimensions and maximum value

    Thanks. it worked . However when I tried to pass the Row values to dynamic , it wasnt possible . I understood that what ever passed between "" is taken as such.

    So is there a way to make the ranges used in this formula to be dynamic?

+ 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: 1
    Last Post: 02-07-2018, 08:00 AM
  2. Create a unique list with a count against the unique values
    By barber87 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-12-2017, 10:13 AM
  3. Counting unique values with several dimensions
    By RuneF in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-19-2017, 07:50 AM
  4. Create unique list from data but listed in order based on a different list
    By Groovicles in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-24-2016, 12:54 PM
  5. Create unique # of worksheets based on list count with unique names
    By Groovicles in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-24-2016, 09:51 AM
  6. Macro to create unique list on new work sheet
    By strud in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-13-2013, 08:29 AM
  7. [SOLVED] create list of unique staff numbers with unique work codes
    By shaz0503 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 01-01-2013, 08:57 PM

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