BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Introducing Visual Basic 10

Introducing Visual Basic 10

Bookmarks

With VB 9 slated to be released sometime this year, Microsoft is already talking about VB 10, also known as VBx. Key features include dynamic code generation like that you would expect in Lisp, Ruby, or Python. This opens up VB.Net for both Silverlight and Office.

VB 9, available in Orcas Beta 1, has all the LINQ goodies we have been talking about for the past year. Libraries compiled with VB 9 can be used in Silverlight just like any other .NET compatible DLL.

VB 10 takes advantage of a Silverlight feature called the Dynamic Language Runtime or DLR. The DLR is an extension on top of the Common Language Runtime (CLR) that supports hosting dynamic languages. In addition, it provides a common object model for dynamic languages.

Like other dynamic languages, the DLR will allow VB 10 code to be compiled on the fly. When combined with Silverlight, this means source code can be downloaded and compiled in the browser at run time, enabling many of the same techniques found in AJAX and other client-side web applications.

An important development for this is the new VM compiler. Unlike earlier VB compilers, which are written in C++, VB 10 will use a compiler written in VB itself. This allows it to run under the CLR and thus gain the cross-platform support promised by Silverlight.

Currently Microsoft Office on Windows still uses the venerable Visual Basic for Applications (VBA 6.5) for macros. Office on OS X will not even have that much according to current plans. With the hosting features of the DLR, it is possible that Visual Basic 10 will finally replace its COM based ancestor as the macro language of choice for Office.

Another feature possible under VB 10 is a REPL or Read-Eval-Print Loop. REPL is a popular feature of dynamic languages in which code is run as it is typed. Currently a very limited form of this is available inside Visual Studio as the immediate window, but this will allow it to leave the confines of VS.

Unfortunately VB 10 was not ready in time for Silverlight 1.1 Alpha 1, but a preview should be available by this year's Professional Developer Conference.

Rate this Article

Adoption
Style

BT