Visual Studio 2022 automatically closing when i try to open it

SYED ALI HUSSAIN 30 Reputation points
2023-06-15T18:28:35.5666667+00:00

I installed a new windows 10 on my pc after installing windows i download the visual studio 2022 community 17.6.2 .After successfull installation of visual studio when i try to launch it ,it closes or crashes after few seconds without showing any error or warning.Even after repairing of visual studio it is showing the same behaviour.My visual studio installer is showing update availability of 17.6.3.Will updating visual studio solve my problem.

Windows for business | Windows Client for IT Pros | User experience | Other
Developer technologies | Visual Studio | Other
Developer technologies | Visual Studio | Other
A family of Microsoft suites of integrated development tools for building applications for Windows, the web, mobile devices and many other platforms. Miscellaneous topics that do not fit into specific categories.
{count} votes

4 answers

Sort by: Most helpful
  1. Reid Klein 90 Reputation points
    2023-06-23T02:09:42.3+00:00

    What I did to fix this issue was:

    1. Remove the contents in folder ...\VisualStudio under this path:
      C:\Users<USERNAME>\AppData\Local\Microsoft\VSCommon\OnlineLicensing\VisualStudio\
      Note: you can backup the contents of this folder for safety if you'd like.
    2. Re-Start Visual Studio
    3. You should be promtped to re-enter credentials if any

    hope this helps!

    18 people found this answer helpful.

  2. Anna Xiu-MSFT 31,121 Reputation points Microsoft External Staff
    2023-06-16T02:43:41.0066667+00:00

    Hi @SYED ALI HUSSAIN

    Welcome to Microsoft Q&A! 

    Please have a try with the following workarounds:

    1. Update the VS2022 to the latest version.
    2. Launch your Visual Studio 2022 in Safe Mode (run devenv /SafeMode in Developer Command Prompt for VS 2022).
    3. Rename the folder: C:\Users\<username>\AppData\Local\Microsoft\VSCommon\OnlineLicensing\VisualStudio.
    4. Restart your Visual Studio.

    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.

     

    14 people found this answer helpful.

  3. Богдан Фадеев 0 Reputation points
    2024-12-25T23:01:26.61+00:00

    In the "local" folder, there is no "Microsoft".

    0 comments No comments

  4. OOraJIANG 0 Reputation points
    2025-10-23T06:46:07.1833333+00:00

    It might be the problem of your vpn! I startup my agent and tackle the problem!

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.