Where Does VS Save Breakpoints and Bookmarks?

a_unique_name 401 Reputation points
2024-05-09T18:04:02.4766667+00:00

TL,DR:

What files do I need to back up in order to recover my breakpoints and book marks? .suo doesn't seem to be enough.

Hello Folks:

Developing on Win 10 Pro, Up to Date VS Community.

One of my routines for backing up my code has been to save space by deleting the .vs directory. I'd build a new set of breakpoints and book marks on the rare occasions I recovered the app.

I've recently started taking advantage of breakpoint groups and bookmark folders.

Now I see, for large applications, breakpoints and bookmarks as resources to invest in and grow over time.

Searches suggest that these are saved in .vs<App Name>\v17.suo.

So I copy the .suo file to a safe directory that will be backed up and delete the .vs directory.

I've recovered the code and and rebuilt the app in order for VS to build a new directory structure. I then copied .suo to its location under the .vs directory.

I'm not seeing any breakpoints or bookmarks.

What more do I need to save in order to recover these two resources?

Thanks

Larry

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,672 questions
0 comments No comments
{count} votes

Accepted answer
  1. Anna Xiu-MSFT 26,481 Reputation points Microsoft Vendor
    2024-05-10T07:30:26.1666667+00:00

    Hi @Larry

    Welcome to Microsoft Q&A! 

    I don’t think you can use the .suo file to recover the breakpoints and bookmarks, although they are stored in the solution's SUO file. 

    If you want to back up the breakpoints, you can export and import your breakpoints as an XML file.

    However, exporting bookmarks is not supported currently. It has been reported to Product Team in Developer Community:

    Allow developers to export bookmarks in Visual Studio - Developer Community 

    Alternatively, you can refer to the similar issue and add a custom token to record your bookmarks. 

    Relevant document:

    Use the Task List to track and use code comments - Visual Studio (Windows) | Microsoft Learn 

    Sincerely,

    Anna


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".  Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

     

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful