Visual Studio 2019 version 16.6 Preview 2 comes with several new, exciting capabilities for you to try today. We recognize that everyone is facing unprecedented stress and concerns with current world events. The Visual Studio team are all working from home and learning how to navigate the challenges that brings to our day-to-day lives. Alas, even in these uncertain times, the team is extremely excited to bring you this latest update. Visual Studio 2019 version 16.6 Preview 2 comes with several new capabilities for you to try. Also, you have the opportunity to offer feedback in Developer Community. As you download and try these new features, we would like to extend our warmest wishes to your health and safety through the upcoming weeks.
Version Control
First of all, we are revamping our Git functionality to provide an improved experience when working with code on remote Git hosting services. You can begin working on code by browsing online GitHub or Azure repositories through Visual Studio and cloning them locally. For new projects, you can initialize the Git repository and push it to be hosted on GitHub with a single click. Once the code is loaded in Visual Studio, the new Git tool window consolidates all the Git operations having to do with your code.
Additionally, this feature streamlines the complex navigation for Git that used to live within Team Explorer. The new window minimizes context-switching between tools and applications by focusing on your daily developer workflows with actions like commit, pull, push, stash, and more. From the tool, you can quickly jump to workflows like the new branching experience. Last, there is also a new top-level Git menu to easily find all of your Git commands. This servers as a replacement of the old Teams menu. We continue to work hard to provide a first-class Git and GitHub experience in Visual Studio, and this is just the beginning.
If you would like to give this a try, toggle on the Preview Feature for New Git user experience in Tools > Options.
Improved Snapshot Debugging Experiences
Based on customer feedback, we wanted to minimize the friction involved in using Snapshot Debugger for the first time. You can now install Snapshot Debugger on Azure App Services (ASP.NET Core 3.1) without requiring a restart. This enables you to debug and diagnose live issues without interruption to your service! Attaching to Snapshot Debugger with Visual Studio Enterprise requires an install of the Snapshot Debugger site extension on your App Service deployment. This process previously required a restart.
New .NET Async Tool
Visual Studio 2019 version 16.6 Preview 2 has a new .NET Async tool as part of the Performance Profiler suite of tools. This adds ease to understanding and optimizing async/await code in .NET. Basically, you can use this tool to get exact timing information for a variety of tasks including how long they waited to be dispatched to a thread, how long it took to complete, and if the tasks were chained together.
New Multi-target JavaScript/TypeScript debugging and Service Worker Support
The JavaScript/TypeScript debugger now supports debugging service workers, web workers, iFrames, and your page JavaScript all at the same time! In addition, the new debugging experience adds support for debugging your back-end node server applications and client-side JavaScript in the browser simultaneously.
.NET Productivity
Almost always providing new updates, the .NET team has added an explicit cast when an expression cannot be implicitly cast. You can access this functionality by placing your cursor on the error and press Ctrl+. to trigger the Quick Actions and Refactorings menu. The option to Add explicit cast beomes available at that point.
Another feedback implementation coming into the product is the ability to automatically generate file headers to existing files, projects, and solutions by using an EditorConfig. If you’d like to give this a try, you can add the file_header_template rule to your EditorConfig file. Next, set the value to equal the header text you would like applied.
Once your cursor is on the first line of any C# or Visual Basic file, you can use Ctrl+. to trigger the Quick Actions and Refactorings menu where the option to Add file banner becomes available. From here you can apply the file header of an existing project or solution by clicking Fix all occurences in. We think this adds some great functionality. Do you?
Also in .NET, you can simplify conditional expressions by removing unnecessary code using the new Simplify conditional expression refactoring capability. Once again, Ctrl+. is the pathway to finding the menu option for Simplify conditional expression. Be sure to give this a try!
Additionally, from the same menu, a new option, Convert verbatim string allows you to convert regular string literals to verbatim string literals. The converse is also true where you can Convert to regular string from verbatim strings.
ML.NET Model Builder
ML.NET Model Builder is also included in this release of Visual Studio! You can enable Model Builder in Tools > Options > Environment > Preview Features.
Once it’s enabled, you can open Model Builder by right-clicking on your .NET project in Solution Explorer and selecting Add > Machine Learning:
What makes ML.NET Model Builder so exciting is you can easily build and consume custom machine learning models for text classification, value prediction, recommendation, and image classification in your .NET applications. All you need to do is select your machine learning scenario and choose your dataset. Model Builder will take care of training models, selecting the best model for your data, and generating the .NET code for consuming the model in your app. You can even scale out to the cloud and take advantage of Azure Machine Learning for image classification models without leaving Visual Studio or .NET.
Web Tools
New experience for configuring Azure services and emulators
The Connected Services tab now offers a new experience for connecting your application to Azure services such as Azure SQL, Storage, Key Vault and many others. It helps you provision new instances or select existing ones. Also, it ensures your code has the most update to date NuGet packages and the right startup configuration code. Wherever possible local emulation options are also available. If you decide to use Publish to deploy your application to Azure the same experience is available within the Profile Summary page minus the emulators.Â
Updates to the Publish Experience
Publishing now offers a new wizard-like experience for creating new publish profiles. This tool guides you through your various options. Even if some Visual Studio components are missing from your installation, you will still have access to the full set of publishing targets and options. Consequently, any of your missing components will be identified and requested to be installed on demand. The publish profile summary page has also been updated to match the new experience available under the Connected Services tab for configuring dependencies to Azure services as detailed above.
Additions to C++
We have added Ninja support for CMake for Linux/WSL. Now, you can use Ninja as the underlying generator when building CMake projects on WSL or a remote system. In addition, Ninja is now the default generator when you are adding a new Linux or WSL configuration. In addition, we have added simplified debugging templates for remote CMake debugging.
We have also improved Doxygen & XML comment generation support by adding the /** trigger sequence and enhancing member list tooltips.
On the same line of adding helpful support, our IntelliSense code linter now underlines code errors and suggests quick fixes in C++ projects. You can enable this tool under Tools > Options > Environment > Preview Features > IntelliSense code linter for C++.
The C++ team has put together blog posts on the Linter and XML commenter if you would like to know more.
In Summary
We have been working hard to keep bringing enhancements to the product. Also, we continue to address any issues brought up in Developer Community, so we invite you to participate with any issues or suggestions. Thank you for giving these features a try! If you’d like additional information on what we are working on next, check out the newly updated Visual Studio 2019 product roadmap. Meanwhile, we hope you and your loved ones stay healthy and safe.
When will there be a Microsoft.Online.SharePoint.Client.Tenant.dll for .Net Core framework?
Asking once again, due to no comment to my previous question:
Is 16.6 the next servicing baseline release? If not, what is the next planned version for the next serviceing baseline release (successor of 16.4)?
Thank you for your patience. 16.6 is not the next servicing baseline, but we are in discussion on which future release will be serviced long term. We will make the announcement when Preview 1 ships as to the baseline status.
Hello. My current VS 16.5.3 shows me a yellow notification "Generate and use Doxygen and XML documentation in the latest Visual Studio Preview. Install More Info". The "More Info" link leads to this very page. All auto update facilities on my machine are turned off for both the Windows and the Visual studio. I do not want even a slightest risk of changing something on this machine. Is there a way to strictly forbid any...
You should set aside a certain amount of days/months where you do a "new features freeze", and focus solely on bug fixing. "Zoom" software CEO announced a 90 day freeze and commitment to focus on security/privacy issues. That's different from VStudio, but still the same concept.
Get the bugs under control, and then put some measures in place that curb the constant introducing of new bugs with new updates. Finally, if you'll just be honest/up-front/transparent with...
When can we expect the Visual Studio 16.6 to have a formal release.
i’m facing the issue mentioned in the below link
https://developercommunity.visualstudio.com/content/problem/893960/compiling-atlsecurityh-raises-several-c5205-warnin.html
Thank you for reporting this issue and for your question. The fix to that issue is now part of 16.6 preview 2. Can you please give it a try? One workaround for 16.5, is to disable the warning. Please see: https://docs.microsoft.com/en-us/cpp/preprocessor/warning?view=vs-2019
Also, I’ve added additional details in the original thread.
Nothing about the old New Project dialog and the old Start Page.
I have upgraded VS2019 16.6 preview 1 to preview 2. Now when opening a windows form in the windows form designer, this error shows up “Object reference not set to an instance object” leaving the designer wiht blank window. Repair of installation has no effect. A colleague to me has the same problem. Using Preview 1 has worked fine so far.
Has anyone else had the problem where code changes weren't compiled when you hit F5? i.e. the debugger just used the last compiled version and doesn't recognize debug points because the code and the pdb no longer match up. I tried using it for an hour right after it came out but got bit by this a couple of times and went back to the release version and life got better. Not...
Simplify conditional expression : Thanks a lot for that.
No problem, I am happy you like it!
Is 16.6 the next servicing baseline release? If not, what is the next planned version for the next serviceing baseline release (successor of 16.4)?