+ Reply to Thread
Results 1 to 5 of 5

Why are dates sometimes collapsed in filter mode and other times they aren't?

  1. #1
    Registered User
    Join Date
    01-20-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2010
    Posts
    63

    Why are dates sometimes collapsed in filter mode and other times they aren't?

    I know the 1st thing you might ask is, what does the date look like in the cell. I've noticed this over many years of working with the filter mode. Its just sometimes they are collapsed and other times they aren't. Sometimes the dates look exactly the same. Usually I just ignore it and go on.

    I totally know its due to formatting. I'm just trying to figure out... Under what circumstances do the dates automatically collapse and under what circumstances do they not.

    For example, I'm working with a sheet of numbers today, the data originated from a CSV file. There are 2 date columns, Both visually appear with the format of dd-mm-yy, and the characters are typed are mm/d/yyy After turning on the filter 1 column appears collapsed and the other does not. I tried to format both columns as short date. they both then change to mm/dd/yyy. But still, 1 collapses and the other does not. I checked the format for individual cells in each column they both appear to have the same format.

    Piddly, irksome problem that I've never figured out.

    note: I tired to import the file and format each column as date. I also opened the csv, copied the data and pasted to a new xlxs file. Same thing happened.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2504
    Posts
    13,633

    Re: Why are dates sometimes collapsed in filter mode and other times they aren't?

    Not sure without seeing your data, but keep in mind that real dates are right aligned in their cell, while text looking like dates are left-aligned ( when no manual alignment is applied). Formatting will not change that, it only changes the way Excel shows the value/text to the outer world.

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,538

    Re: Why are dates sometimes collapsed in filter mode and other times they aren't?

    Changing the formatting will have no effect unless the values are genuine dates. If you change the format to General and one or other or both still look like dates, then it's text that looks like a date.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  4. #4
    Registered User
    Join Date
    01-20-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2010
    Posts
    63

    Re: Why are dates sometimes collapsed in filter mode and other times they aren't?

    I think I discovered my own answer.
    When using the Filter Mode for dates, EXCEL using "grouping" and by default shows the top level of "grouping".

    When using the Filter Mode on a sheet containing dates... Sometimes the dates will appear in the filter box as collapsed within its own month, sometimes the filter box will show the dates expanded as a list.
    EXCEL uses the filter box to group dates.
    • It seems that if the filtered column contains only dates of a singular month, they are expended by default. Showing the dates as a list or, within the "group" of a singular month. Because there is only 1 "group".
    • If the column contains dates from more that 1 month or any other kind of data, the list appears collapsed by default, grouping the dates into their "group" by month and any other kind of data below the months or "groups". Since there is more than 1 "group", it defaults to the top level of "grouping".


    My sheet had 2 columns of dates. 1 column had dates from a singular month. Excel expanded the group be default. The other had dates from 2 different months and additionally 3 cells with "--", therefore that filter box showed the dates collapsed into their own month and the "--" listed below the 2 months.

    There are probably other specific behaviors for the filter mode that I haven't discovered yet. But at least I understand this now.

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,538

    Re: Why are dates sometimes collapsed in filter mode and other times they aren't?

    Thankyou for sharing your solution.


    If you are satisfied with the solution(s) provided, please mark your thread as Solved.


    New quick method:
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

    Or you can use this way:

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save


    You may also want to consider thanking those people who helped you by clicking on the little star at the bottom left of their reply to your question.

+ 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. Web scraping - check if filter list is expanded or collapsed
    By GreenSnake in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-26-2020, 04:21 AM
  2. Saving reports to .pdf and 'design mode' pictures aren't changing.
    By KevinSonomatic in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-20-2014, 04:46 AM
  3. [SOLVED] Formula for couting unique dates in filter mode
    By qaiserniazi in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-20-2013, 04:15 AM
  4. Replies: 1
    Last Post: 08-25-2011, 04:42 PM
  5. Advanced Filter with dates and times
    By kt1978 in forum Excel General
    Replies: 3
    Last Post: 01-31-2011, 05:54 AM
  6. Mode Between Two Serial Dates/Times
    By ChrisM in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-17-2005, 10:15 PM
  7. Mode between two serial dates/times
    By ChrisM in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 11-17-2005, 05:45 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