Original URL: http://www.theregister.co.uk/2013/11/27/visual_studio_2013_review/

Visual Studio 2013: 50 Shades of Grey not a worry for MONSTER dev TOOL

Improvements all 'round, but buggy on cloud and devices

By Tim Anderson

Posted in Applications, 27th November 2013 12:32 GMT

Review How good is the latest iteration of Microsoft’s monster development tool, Visual Studio 2013?

Visual Studio is the product that has to follow all the twists and turns of Microsoft’s developer story. Unlike Visual Studio 2012, which introduced a controversial makeover that removed most of the colour from the IDE, this is a relatively minor update, though the size of the product is such that there are still notable changes.

Visual Studio is loosely coordinated with new versions of Windows, making this the Windows 8.1 edition. The .NET Framework moves from version 4.5 to 4.5.1 and you will hardly notice.

The recently released Visual Studio 2013 introduces a new application type called a Cloud Business App. This brings together the LightSwitch rapid application builder and the Office 365 cloud platform.

LightSwitch, introduced in 2010, allows you to define data tables using a simple visual designer, and then generates screens for viewing and editing the data. The original version built Silverlight clients, but the latest incarnation supports responsive HTML clients. You can add snippets of code, using JavaScript on the client or C# on the server.

A Cloud Business App throws SharePoint or Office 365 into the mix. Lack of documentation and perplexing deployment dialogs spoil the ease of use, as does a bug which prevents the saving of data in debug mode, but I was eventually able to deploy a simple app to an Office 365 team site.

Cloud Business Apps are interesting for a couple of reasons. One is that building line of business applications on Microsoft’s platform is in some respects harder today than it was 10 years ago, hence the LightSwitch focus on easy development. Secondly, Office 365 and Azure now form a more strategic platform than the Windows client, since they are cloud-based and can support cross-platform clients.

Visual Studio 2013

Visual Studio 2013, the latest version of Microsoft's do-it-all IDE (click to enlarge)

Are Cloud Business Apps good enough to use, though? They fall more in the “promising” category, with missing features (no reporting for example) and an odd combination of simplistic tools and underlying complexity.

Most developers will fall back to the tried-and-trusted ASP.NET, for which Visual Studio now offers a unified project template sometimes called One ASP.NET. Select a new ASP.NET project and you can check the features for which you want support, mixing and matching from Web Forms (the old way), MVC (the new way), Web API (for a web services application), and unit tests. You can also choose an authentication option ranging from internal accounts and Azure Active Directory (which works with Office 365) to traditional Windows intranet.

A scaffolding framework has been added to ASP.NET in Visual Studio 2013, for code generation based on a data model. There is also a new HTML editor with IntelliSense code hints for frameworks including JQuery UI and AngularJS, and an editor for CoffeeScript (which compiles to JavaScript) and LESS, which extends CSS.

In Visual Studio 2013, Microsoft has successfully simplified deployment to Azure, so you really can have your web application publicly accessible on an Azure website in moments. Azure deployment is based on publisher profiles, which the deployment wizard can retrieve automatically after you authenticate with an Azure account. Choose Web Deploy, hit Next, hit Publish and there it is; a great way to impress clients with a quick prototype.

Visual Studio 2013 Cloud App

Building a Cloud Business App starts with a table definition that automatically generates screens (click to enlarge)

The one thing that spoils this easy deployment is that Windows – and therefore Visual Studio – gets easily confused if you use multiple sign-ins, such as more than one “Organizational” (that is, Office 365) accounts, or mixed Organizational and Microsoft (that is, Windows Live) accounts. Stuff then fails to work.

Some confusion is hard to avoid, especially given that the IDE now synchronises settings between all the machines upon which you work, provided that you sign in with a Microsoft account. Synchronized settings covers theme, fonts, and text editor options.

Speaking of the editor, there are some neat enhancements, some of which were previously available as add-ons. The best is called CodeLens. When enabled, this creates hyperlinks above every class and method, showing the number of references to that code, the number of unit tests and how many pass, outstanding bugs and work items, code reviews, and changes. The hyperlinks work inline, so you do not lose your place in the code unless you click a second link within the window that pops up. Click the references link, for example, and all the instances of calling code are listed.

I have heard complaints that CodeLens clutters the code, but you can disable it if you prefer. More annoying is that it only works in the Ultimate edition and with C# or Visual Basic.

Chaotic diversity

Another feature, called Peek Definition, works in all editions down to Professional. This right-click option is similar to Go To Definition, but shows the code that defines the current type in an inline popup window. You can edit as well as view the code. The idea is to avoid losing your place or opening multiple code windows unnecessarily.

A debugging feature called Edit and Continue now works in 64-bit as well as 32-bit .NET applications.

What of Windows Store app development, apps for the controversial Windows Runtime environment in Windows 8? Language-wise you can code in C#, Visual Basic, C++ or JavaScript, which means most developers will find something familiar. The available .NET Framework is considerably cut down, which can delay coding as you look for workarounds to missing pieces, but coding the logic for a Windows Store app is straightforward.

Visual Studio 2013 One ASPNET

ASP.NET projects: now with multiple frameworks and Azure Active Directory (click to enlarge)

The user interface aspect is less satisfying. There is a visual designer in Visual Studio for XAML, but not for HTML, though a separate application called Blend offers visual design for both. The choice then is to live with the basic designer in Visual Studio, or put up with constant switching between tools. Blend is oriented towards designers rather than developers, making Store App development harder than it should be.

This part of Visual Studio also seems somewhat buggy. The Visual XAML designer in Visual Studio regularly fails for me with meaningless messages like “Page is not supported in a Windows App project” (untrue). Change from debug to release mode and back and it works again, for a bit.

The tools for Windows Phone are similar, though in this case you are coding to Silverlight rather than the .NET Runtime, unless you choose C++ native development.

Visual C++ gets a new REST SDK in this release, codenamed “Casablanca”, though you can also use it in Visual Studio 2012. The compiler has improved standards compliance, with key improvements to C++ 11 support including default template arguments, variadic templates and alias templates. Some parts of C++14 are implemented for the Standard Template Library.

There is also belated support for more of C99, and missing functions implemented in C99 libraries, including math.h, stdio.h, stdlib.h and wchar.h. The main purpose is to improve compatibility with cross-platform code including open-source libraries.

The C++ editor has several enhancements which include auto-completion of braces, brackets, quotes and parentheses.

Visual Studio 2013 phone app

You use Blend to design a Windows Phone app (click to enlarge)

Microsoft’s application lifecycle and team support is increasingly web-based. Visual Studio Online, a hosted version of Team Foundation Server (TFS), is free for up to five users for the Basic edition, which includes Git or TFS source code management, project-planning with sprints, backlogs and work items, and continuous integration with cloud build services. Additional users cost $10 per month, which will rise to $20 per month at an unspecified future date.

Visual Studio Online Professional costs $22.50 (rising to $45.00) per user/month, includes a subscription to Visual Studio Professional, and supports up to 10 users. Beyond that you need Advanced at $30 per user/month (rising to $60), including Team Rooms for online collaboration, Feedback requests and more.

Visual Studio Online is an especially good deal for small teams who can get by with the free Basic edition, and makes a welcome change from the complexity of setting up your own Team Foundation Server. There are still occasional annoyances, like the laughable error when trying to build a Store app on the Microsoft’s own hosted build server that says: “No valid developer license found for running unit tests for Windows Store apps.”

Visual Studio editions start with free Express versions for Windows Store, Windows Desktop, Web or Windows Phone. After that there is a range of options, from the basic Professional Edition for around £500 through to Ultimate with MSDN at £11,235 (renewal a mere £3,560).

With rival platforms vying for developer attention, it is not surprising that Microsoft invests so much in its developer tools, and with generally good results. The size and complexity of the IDE reflects the breadth of the Microsoft platform, or being less polite, its chaotic diversity, across Windows desktop, Windows Store, Windows Phone, ASP.NET, SharePoint and SQL Server.

Cloud integration is getting better, with Visual Studio Online and Azure integration both strong points, though Microsoft still has work to do making sense of Office 365 development and bringing some sanity to cloud account management.

Visual Studio is more complex than it should be for those looking for a quick route to developing a line of business app. LightSwitch is meant to address that, but its peculiarities and some gaps in the implementation spoil its impact.

ASP.NET, on the other hand, is excellent, thanks to being allowed to evolve without the strategic shifts that have disrupted the Windows client and devices.

Despite some annoyances, this is a solid upgrade to Visual Studio 2012. ®