Turn on to Microsoft’s LightSwitch

Microsoft announced Visual Studio LightSwitch in August 2010 and has recently released a second, fully functional beta version.

Turn on to Microsoft's LightSwitch

This addition to the Visual Studio family aims to provide a simple, fast way to produce line-of-business applications: you start building a LightSwitch application with the data, drawn either from an existing database or from one you define yourself, and quickly build a model of that data. LightSwitch then enables you to easily define screens that employ that model to create, edit or query the data.

Provided you have a reasonably good understanding of the data you want to use, the development process is astoundingly quick compared with traditional development methods, because LightSwitch supplies all the necessary plumbing, with virtually no coding required.

The development process is astoundingly quick compared with traditional development methods, because LightSwitch supplies all the necessary plumbing, with virtually no coding required

For instance, every form (screen) you define knows when its data is “dirty”, automatically displays an asterisk in its tab, and prompts you to save that data when you try to close the form.

LightSwitch knows from the database which fields must be filled – that is, those that aren’t nullable – and displays their labels in bold. It also knows what an email address should look like, so will validate user input into any field you’ve marked as holding an email address.

More tricks

Enabling you to get a good-looking business application up and running in 15 minutes or less is remarkable enough, but LightSwitch has more tricks. Its applications are built using a long list of up-to-the-minute technologies, including Silverlight, MVVM, Linq, OData, WCF and JSON, which means they can be secured, extended and scaled with ease:

• Silverlight is Microsoft’s rival to Adobe’s Flash. In effect a cut-down version of the Windows Presentation Foundation designed to replace the procedural Windows Forms screen design language with a declarative XML-based language called XAML;

• MVVM (Model-View-ViewModel) is an architectural pattern that evolved out of Microsoft’s earlier MVC (Model-View-Controller) pattern. It asks you to define a Model of your data, a View onto that data, and a “View-Model”, which is the glue that binds the data to the view. Such a methodology encourages good separation between layers within an application, and it’s automatically implemented in LightSwitch with no effort on your part;

• LINQ stands for Language Integrated Query, an extension to C# and VB.NET that enables programmers to run SQL-like queries on strongly typed objects and collections;

• OData is the Open Data Protocol, which allows access to SQL Server data through HTTP-based web technologies. It’s used in SharePoint, PowerPivot and SQL Azure;

• WCF is Windows Communication Foundation, a set of standards for communication between processes running on different physical or logical machines, including ways of verifying identities, authenticating requests and securing data;

• JSON is JavaScript Object Notation, a lightweight data-interchange format used to serialise complex objects for communication over the web.

As a developer you don’t need to know anything about these advanced technologies to use LightSwitch. You only need to know where your data is held, then point LightSwitch at that data and the application almost writes itself.


You can literally go from a raw database to a good-looking, working application in minutes, but spend a little longer and you can have a great, useful application that anyone can use.

Of course, as more people want or need your little application, you may run into questions about security, scalability, compliance and maintenance. Had the application been written in Excel or Access, there would be severe obstacles to scaling and deployment that required the original code to be scrapped and rewritten.

Disclaimer: Some pages on this site may include an affiliate link. This does not effect our editorial in any way.

Todays Highlights
How to See Google Search History
how to download photos from google photos