CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    John E is offline Elite Member Power Poster
    Join Date
    Apr 2001
    Location
    Manchester, England
    Posts
    4,835

    Missing 'convenience filters after restoring from a backup

    Does anyone know what generates the 'convenience folders' (filters) in a VS solution? Here's the kinda list I usually see in my IDE:-

    Name:  usual-list.png
Views: 475
Size:  11.9 KB

    Notice that the header files are in a separate filter from source files / resource files etc. Unfortunately I just needed to restore some projects from a recent backup and I seem to have lost those filters (which are quite useful). Apart from External Dependencies, everything is now jumbled together:-

    Name:  restored.png
Views: 528
Size:  12.0 KB

    If it was just one project I could just set them up again - but I've restored over 20 projects.

    Does anyone know what associates the various files with their respective filters (i.e. do I need to re-associate them somehow?) Or will it be a matter of laboriously recreating them all over again...

    [Edit...] I just discovered that each project has an associated file called <the_project_name>.filters, These did get restored but for some reason they haven't been re-associated with the project. Any ideas anyone?
    Last edited by John E; November 20th, 2020 at 10:33 AM.
    "A problem well stated is a problem half solved.” - Charles F. Kettering

  2. #2
    John E is offline Elite Member Power Poster
    Join Date
    Apr 2001
    Location
    Manchester, England
    Posts
    4,835

    Re: Missing 'convenience filters after restoring from a backup

    It seems to fix itself if I remove each project from the solution and then re-add it (it then comes back associated to its .filters file somehow). A bit annoying but at least it fixes itself...
    "A problem well stated is a problem half solved.” - Charles F. Kettering

  3. #3
    John E is offline Elite Member Power Poster
    Join Date
    Apr 2001
    Location
    Manchester, England
    Posts
    4,835

    Re: Missing 'convenience filters after restoring from a backup

    Things seem to be going from bad to worse...

    When I loaded that solution file this morning, all those projects have gone back to their jumbled state (i.e. with no filter folders any more). But that's not the worst of it... if I right-click on any of them and choose Properties, a message box appears saying:- There are no property pages for the selection

    And even weirder.. the exact same project files can be loaded successfully into a newly created solution. So I'm guessing something in that solution has gotten corrupted somehow.

    I've noticed that each VS2019 solution seems to contain 2 files called Browse.VC.db and Solution.VC.db. Does anyone know if those files can be safely deleted (i.e. will they get regenerated?) Or are there any others I should be looking at?
    "A problem well stated is a problem half solved.” - Charles F. Kettering

  4. #4
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Missing 'convenience filters after restoring from a backup

    Try it. Make a copy of the complete solution and then delete the .db files.

  5. #5
    John E is offline Elite Member Power Poster
    Join Date
    Apr 2001
    Location
    Manchester, England
    Posts
    4,835

    Re: Missing 'convenience filters after restoring from a backup

    Thanks Arjay - literally just a few minutes ago I think I found the problem

    All of these project files share a common .props file which mostly contains a series of build paths to the other projects - but one of those paths had somehow acquired an @ character (and I think '@' is illegal in a filepath ??)

    I haven't yet figured out how the @ character got there but I've corrected it manually and it seems to have fixed the problem. Total fluke that I found it...
    "A problem well stated is a problem half solved.” - Charles F. Kettering

  6. #6
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Missing 'convenience filters after restoring from a backup

    Are you using source control? If not, you might consider it. It comes in handy for doing file diffs and seeing what's changed.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured