+ Reply to Thread
Results 1 to 2 of 2

Filter Macro Help

  1. #1
    Registered User
    Join Date
    04-29-2016
    Location
    Albuquerque, New Mexico
    MS-Off Ver
    2013
    Posts
    3

    Filter Macro Help

    Hello Excel Community,

    I have been struggling with coming up with a macro.

    I have a column in a spreadsheet that has a list of values some same, some different. This column will be sorted so that it goes ascending from greatest to lowest values and thus same values will be next to each other.

    What I am trying to do is have my macro go down this list and insert a row as to seperate rows to isolate similar rows with the same value. For example:
    i have I want
    134586545
    134586545 134586545
    134586545 134586545
    134586545 134586545
    134586545 134586545
    134586545
    354565463 354565463
    354565463 354565463
    354565463 354565463


    so far my code looks like this:


    Please Login or Register  to view this content.

    Unfortunately this only works for sets of 2 values and not more. I cant think of a work around to create a space for groups of values with different amounts.

    As you can also tell, I have lngrow*3 to account for the spaces the macro does make.

    Any help would be greatly appreciated.

    Thanks Peeps!
    Last edited by jeffreybrown; 06-24-2016 at 06:42 PM. Reason: Please use code tags

  2. #2
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481

    Re: Filter Macro Help

    Hi there,

    See if the attached workbook does what you need. It uses the following code:

    Please Login or Register  to view this content.
    The highlighted values can be altered to suit your requirements.


    Hope this helps - please let me know how you get on.

    Regards,

    Greg M
    Attached Files Attached Files

+ 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. Macro to filter a pivot whilst looping through filter criteria in a variable list.
    By Alistairm88 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-29-2015, 04:25 AM
  2. [SOLVED] I need formula or macro to filter a number of items from different tables at single filter
    By Karthikeyannb in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-05-2014, 11:04 AM
  3. Need to filter a report filter based on the previous filter
    By elliotencore in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 01-28-2014, 07:44 AM
  4. Replies: 5
    Last Post: 12-19-2013, 06:58 AM
  5. Filter Macro (range contained in filter value)
    By antman10 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 11-28-2010, 11:09 PM
  6. Advanced Filter Macro - Won't run the filter
    By dsil in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-18-2008, 11:59 AM
  7. Need macro to filter, create tab on filter and copy/paste
    By Jen in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-02-2006, 11:50 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