Visual Studio 2019 version 16.2 Preview 2

Jacqueline Widdis

We are announcing the release of the second preview of Visual Studio 2019 version 16.2. The latest version is available for you to download from, or, if you already have the Preview installed, just click the notification bell from inside Visual Studio to update. This latest preview adds the ability debug JavaScript code using the new Microsoft Edge Insider, an improved installation experience, and updates to the application installer command-line packaging. We’ve highlighted some of the notable features below. You can see a list of all the changes in the release notes. 

Microsoft Edge Insider support 

The latest preview release of Visual Studio enables debugging JavaScript in the new Microsoft Edge Insider browser for ASP.NET and ASP.NET Core projects. To do this, simply install the browser, set a breakpoint in the application’s JavaScript and start a debug session. Visual Studio will launch a new browser window with debugging enabled allowing you to step through your JavaScript code within Visual Studio.

But it doesn’t stop there since Visual Studio also supports debugging custom browser configurations using the “Browse with” option to launch the browser with custom CLI parameters (e.g. inprivate).

Visual Studio Installer support 

The Visual Studio Installer will now better handle size space detection based on what you already have installed on your machine. The improved installer experience means that if the required amount of space is larger than what is available, the installation does not attempt. 

.NET Productivity Improvements 

The latest preview release continues to focus on developer productivity and we bring even more refactoring capabilities to enable you to write better code faster. We’ve heard the request to bring back the Sort Usings command and that it should be separate from the Remove Usings command. We appreciate everyone who shared their feedback with usYou can find the Sort Usings command under Edit > IntelliSense.

We’ve also added the ability to convert a switch statements to switch expressionsSince switch expressions  are a new C# 8.0 featureyou need to ensure that you’re utilizing the latest language version, i.e. C# 8.0. Under project file, verify the language version is set to preview. Place your cursor in the switch keyword, type (Ctrl+.) to open the Quick Actions and Refactorings menu, and then select Convert switch statement to expression. 

Finally, we’ve added the ability to generate a parameter as code fix. Place the cursor in the variable name and type (Ctrl+.) to open the Quick Actions and Refactorings menu. Select the option to Generate a variable to create a new parameter. 

App Installer Command Line Packaging Improvements 

In Visual Studio 2019 version 16.2 Preview 2, we improved the sideloaded command line packaging experience for Windows Desktop projects and, in particular, those that are configured to receive automatic updates using an .appinstaller file.   

In previous versions of Visual Studio, you were required to use one of three different methods to properly set the HoursBetweenUpdateChecks update setting in the .appinstaller file. You could use the Packaging Wizard to package the application, add the AppInstallerUpdateFrequency and AppInstallerCheckForUpdateFrequency build properties to the project file, or pass these parameters as command line arguments. 

In Preview 2, we have eliminated the need to use the Package Wizard or define these build properties.  Instead, you are able to simply define and pass HoursBetweenUpdateChecks as a parameter during the command line build, simplifying and making it easy to adjust that setting. 

Take it for a spin today 

Give the latest Preview release a try by downloading it online, or updating via the notification bell inside Visual Studio. You can also launch and use the Visual Studio Installer to install the update. 

Our PM team is always reviewing feedback and we look forward to hearing what you have to say about our latest release. If you come across any issues, make sure to let us know by using the Report a Problem tool in Visual Studio. If you have any feature ideas or want to ask questions, you should head over to Visual Studio Developer Community. We use your feedback to decide what to work on as we pursue our goal to make Visual Studio 2019 the best developer tool, so thank you again on behalf of our entire team. 


Discussion is closed. Login to edit/delete existing comments.

  • Dean Jackson 0

    What if you won’t be providing any updates to your application anytime soon, and you will be notifying people manually that there is an update…and in that case you don’t want or need the application to check for updates?  Is there a setting that disables update checks?

  • Stephen Owen 0

    You know what would be so cool? When I have a dotnet core project I can debug using any of my project configs to test my project against my local DB, or dev, uat and even prod. But in 4.6 I have to copy and paste web.config files over each other rlike a caveman. It would be cool to have a dorp down box near the debug button to pick which web.config I want to apply.

  • Guillermo Perez 0

    I am very disappointed… I did post that I am unable to set up a Blazor to work out of the box… The reason is that inside the options of VS an option should appear to enable the use of preview versions but the box is not there… I have notified this problem but days have passed and I have not received any answer… My question is… how is this possible that nobody has noticed that problem? Now I see a new version of VS and the problem probably still there… Nobody uses VS 2019 and Blazor?

    • Petr Onderka 0

      Are you running into the same problem as I think the preview option was moved, so maybe you’re not looking in the right place?

  • René Spišák 0

    I like “Remove and Sort Usings” feature. For this and “Format on Save” I’m still using Power Commands extension from original Productivity Power Tools.Will there be any way how to enable this feature on save? That’s one of the most important things I’m really looking for in Visual Studio without extensions. “Remove and Sort Usings”, “Format code” and “Run cleanup” on file save.

    • Yann Duran 0

      I like that you can now remove unused usings without having to sort them, but I agree with you about running them on save.
      It’d be awesome, if there was an On Save setting, with the ability to tick boxes for things like: 
      [ ] Remove Unused Usings,
      [ ] Sort Usings,
      [ ] Format Code,
      [ ] Run Clean up

  • SuperCocoLoco . 0

    And what about the restore the old start page and old new project window? All users want this and are reclaiming this in order to VS 2019 be useable and to migrate from VS 2017.

    • Scott Marzigliano 0

      Tools, Work Items, General,  Landing Page – Legacy

      • SuperCocoLoco . 0

        Thanks! Now only need the restore of the “New project” window.

  • Dean Jackson 0

    Can update checking be disabled for AppInstaller projects ?

Feedback usabilla icon