BT

Your opinion matters! Please fill in the InfoQ Survey!

.NET Core 2 Brings Visual Basic to Linux and macOS

| by Jeff Martin Follow 6 Followers on Aug 23, 2017. Estimated reading time: 1 minute |

A note to our readers: As per your request we have developed a set of features that allow you to reduce the noise, while not losing sight of anything that is important. Get email and web notifications by choosing the topics you are interested in.

Microsoft has moved closer towards bringing Visual Basic into place as a first-class citizen on the .NET Core platform.  As part of the .NET Core 2 release, VB developers can now write console apps and class libraries that target .NET Standard 2.0-- and all are multiplatform compatible.  This means the same executable or library that runs on Windows can work on macOS and Linux.

Once the .NET Core 2 SDK is installed, you will have the ability to start creating VB projects.  Since this is .NET Core, Visual Studio is helpful but not required.  Four VB templates within 2.0:

  • Console Application - sample Hello World app
  • Class Library
  • Unit Test Project
  • xUnit Test Project

From a command prompt, you can run:
dotnet –version

to confirm that you are on .NET Core 2.0 or greater.  Then create a new directory to hold your new project, and run dotnet new to create a new project based on one of the templates.  Then run dotnet run to launch the project:
mkdir vbcore
cd vbcore
dotnet new console -lang VB
dotnet run

    
This doesn't mean that Microsoft's work is done however, as work remains for VB developers on .NET Core to gain the ability to use ASP.NET Core.  Templates for that are in the works per Microsoft’s Immo Landwerth but are not available with this release.  However, VB developers can now write cross-platform code for macOS and Linux, something that was not possible in a supported manner until now.

Rate this Article

Adoption Stage
Style

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread
Community comments

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Discuss

Login to InfoQ to interact with what matters most to you.


Recover your password...

Follow

Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.

Like

More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.

Notifications

Stay up-to-date

Set up your notifications and don't miss out on content that matters to you

BT