Future blogs on Visual Basic can be found on the official .NET blog going forward.
Visual Basic Blog
A group blog from members of the VB team
Latest posts
Visual Basic support planned for .NET 5.0
We’ve heard your feedback that you want Visual Basic on .NET Core. Visual Basic in .NET 5 will support additional application types.
Visual Basic in .NET Core 3.0
Visual Basic in .NET Core 3 Update: March 12, 2020 This strategy described in this 2018 post has been replaced with the one in this post. Update: Oct 8, 2019 .NET Core 3.0 contains portions of the Visual Basic.NET Runtime (microsoft.visualbasic.dll) that do not depend on WinForms. Visual Basic.NET support for WinForms, WPF, and other application types in .NET Core 3.0 is similar to C#. Special features of the Visual Basic.NET Runtime (microsoft.visualbasic.dll) are not in .NET Core 3.0. As an example, application startup using application models are not supported. Visual Basic.NET desktop templates...
Combining Angular, Visual Basic and .NET Core for developing modern web apps
Visual Basic supports .NET Core starting in Visual Studio 2017 Update 3 (15.3). This opens new possibilities for new applications and modernizing existing applications. Preserving domain-specific code when modernizing applications allows step-wise conversions, decreases cost, and avoids disruptions. This post covers using Visual Basic ASP.NET Core WebAPI for the back end, along with a new TypeScript and Angular front end. Working in Visual Basic lets you work in your favorite language and reuse existing business logic. The TypeScript/Angular front end provides a responsive SPA (single-page-application) user inter...
Roslyn Primer – Part I: Anatomy of a Compiler
So, you’ve heard that VB (and C#) are open source now and you want to dive in and contribute. If you haven’t spent your life building compilers, you probably don’t know where to start. No worries, I’ll walk you through it. This post is the first of a series of blog posts focused on the Roslyn codebase. They’re intended as a primer for prototyping language features proposed on the VB Language Design repo; and contributing compiler and IDE features, and bug fixes on the Roslyn repo, both on GitHub. Despite the topic, these posts are written from the perspective of someone who’s never taken a course in compilers (I ...
Dependency Injection with Visual Basic .NET – Part 2 – IoC Containers
This post was authored by guest blogger André Obelink, a Visual Basic MVP, and published by the VBTeam on his behalf. In my previous post, I wrote about the basics of dependency injection. I explained the technique to define an interface and injecting the dependencies to a client object. These dependencies contain the real implementation of that specific interface. Applying dependency injection makes your code more loosely coupled, which helps you in maintaining, extending, and testing your codebase. The example we ended up with works fine, but it can still be improved for some scenarios. In this post I will sho...
Dependency Injection with Visual Basic .NET – Part 1
This post was authored by guest blogger André Obelink, a Visual Basic MVP, and published by the VBTeam on his behalf. In this first blog post of a series of two, I explain what dependency injection (DI) is and why you might want to use this design principle in your software. The target audience of this post is the junior / medium experienced software developer, with no knowledge of dependency injection or related techniques. In the second post, I’ll describe the use of Inversion of Control Containers (IoC containers), to use dependency injection in a much more flexible way. What is dependency injection? Dependenc...
New for Visual Basic: .NET Standard Class Libraries and the dotnet CLI!
Visual Studio 2017 15.3 Preview 1 included templates for VB class libraries targeting .NET Standard class libraries and for .NET Core console apps. With the release of .NET Core 2.0 today those templates go-live. The .NET Standard You can use the built-in templates to create cross-platform command-line apps, as well as creating and testing cross-platform VB libraries targeting the new .NET Standard. When you target a version of the .NET Standard you get access to all the APIs included in that version of the standard. You can then use that single library in any app targeting a platform that supports that version...
Visual Basic and Cross-Platform: Mobile Apps with VB, Xamarin, and .NET Standard!
How would you like it if you could create a Console App in Visual Basic and run it on Linux? Or running the same Xamarin.Forms-App written in Visual Basic on an iPhone, and Android and a Windows Tablet? Welcome to the world of cross-platform development, which from Visual Studio 2017 Update 3 on – thanks to .NET Standard and .NET Core – is now also available for Visual Basic! Well, currently the preview of Visual Studio 2017 lets you use this, and it is the best set of features that Update 3 (aka VS 15.3) will bring for us VBs: We are getting Visual Basic .NET Core and .NET Standard templates. Note though, that t...
Introduction to (Live) Unit Testing in Visual Basic… [updated for VS 2017 Update 3 Preview 3]
...and Why My Grandma Invented the Concept! Meet late Grandma Grete Schindler. I'd like to introduce you to my grandma, because this post will be about the essence and purpose of unit testing in Visual Basic, and Granny Grete basically invented the concept of unit testing. Yes, she really did, I kid you not – she was a very wise woman! When she saw someone in our family doing their work in a hectic rather than a thoughtful way, she always quoted her most favorite Silesian proverb: “Kinder, schmeißt nicht mit dem Hintern um, was ihr mühsam mit den Händen aufgebaut habt” – which roughly translates to “Kids, ...
Easy Async and Await for VBs Part 1, or…
...letting your code do absolutely nothing! We’ve all been there, one way or the other. Either as users of an app or as the developer to whom users complained to: When a typical Win32 app is waiting for an operation to complete, we often get to see something like this: In discussions about how to get a handle on such scenarios there are all kinds of suggestions, one of the most frequent ones being “You need to do this asynchronously: Just start a new thread! You can do that with Tasks.” And this is when people start introducing patterns like the following into their code which in most cases is not only unnecessa...
Why VB2017 only supports consuming ref returning methods
Hi VBers, Last week Klaus wrote an amazing post detailing a number of improvements made to the Visual Basic IDE and language in Visual Studio 2017 (and he even forgot one, stay tuned for awesome). Regarding the new ref-return feature Jonathan Allen inquired as to why the design was so different from the one in C#. It's not uncommon for considerations in one language to be different in the other or for the styles of the languages to yield different design decisions, even from the same people. But it's a great question so I thought I'd write up a longer explanation for the VB design. To put it bluntly, the capabili...
What's New in Visual Basic 2017
Visual Studio 2017 just shipped, and with it shipped a new version of Visual Basic. With the new language strategy of the .NET Languages, the focus is again on Visual Basic’s original virtue: Provide editor, debugging and refactoring tools as well as language feature to ease complex tasks and boost every VB’s developer productivity without distracting them from their domain specific excellence. After all, it always was first Visual Basic which put the ‘Visual’ into Visual Studio, and let developers get the work done efficiently, yet without compromises in quality! 😎 Speed up Solution Loading times with Enable Lig...
Digging Deeper into the Visual Basic Language Strategy
Today Mads made an excellent post about our overall .NET Language Strategy. As I know this will raise a lot of questions in the VB community I wanted to take an entire post on the VB team blog to dive deeper into how VB fits into that strategy and why and what that means in practical terms for us as a community. Looking Back Six and half years ago, the Visual Studio Languages team laid out the motivations for our then-new co-evolution strategy. Mainly the significant overlap in adoption between VB and C# in adoption and use cases and four "powerful unifying forces" they shared: What's Changed? ...
Relaunching the Visual Basic Team Blog
Last year we decided to retire this blog and consolidate content on the .NET team blog instead. The thinking at the time was that we weren’t really posting a lot of content to it and that there was so much overlap in content between the VB team blog and the C# FAQ that it would be simpler to just focus on the .NET blog. Since then my experience has been that the Visual Basic community still needs a place of its own to discuss topics uniquely relevant to VB developers so we’re relaunching this blog. The .NET team blog will continue to be the source for the latest information on the .NET platform; which is of cours...
New VB T-Shirt Designs on the .NET Blog – Tell Us What You Think
[Update: You can get these cool T-Shirts @ the .NET Swag Store - get yours today!] Mads and Dustin showed off their cool VB and C# team t-shirts at BUILD and tons of people liked them and asked where they could get one. So, we're thinking about making them available for purchase online. I've been working on some new designs and would love to know what you think. See the designs and leave your feedback on the full post over on the .NET team blog. Regards, -ADG
Roslyn ships v1.0-rc2 with "Go-Live" license
For the last six years you've heard us go on and on about this Roslyn thing and how it's the platform for the future and would change everything and that we were all-in on it and "it's going to be great just wait and see". Well, the wait is over. This morning, at BUILD, Principal Program Managers of the Managed Languages Team Mads Torgersen and Dustin Campbell showed during their "What's New in C# 6 and Visual Basic 14" talk that Roslyn is here and Roslyn is ready. As of yesterday Roslyn has a "Go-Live" license. This is the culmination of over half a decade of design and investment from some of the brightest min...
A Journey Through Open Source: The Trials & Triumphs in Roslyn's First Year of Open Source
"I am looking for someone to share in an adventure." — Gandalf, The Hobbit, J.R.R. Tolkien On April 3, 2014, Anders Hejlsberg set us on our open source journey when he made the .NET Compiler Platform (aka “Roslyn”) source code public live on stage in San Francisco. Without much open source experience to guide us (or a Grey Wizard), we anxiously yet excitedly hit the open roads. This post details the real and true story of the trials and triumphs we’ve experienced in Roslyn’s first year of open source. The Call to Adventure Previously, in order for developers to build a code-...
Lowercase Keywords Revisited (not an April Fools’ Day joke this time, I promise)
Hey all, I hope you enjoyed yesterday's April Fools' Day post. I thought it was a fun way to kick off an experiment I'd like to conduct and in this post I'll tell you how you can actually try out lowercase keywords for VB on your machine right now no matter what version of VS you're using (no joke). You see, a few years back Architect-emeritus Paul Vick asked a question, "Do PascalCased keywords make VB look more verbose than it really is?" At the time I didn't really give the question enough thought but a lot of commenters responded positively about the look (both then and yesterday) and recently I got to thin...