I still remember being in Detroit in late 2002 with a conference room full of developers, Microsoft was pitching the wonders of a brand new framework called .NET. The pitch that really pulled me in was that the CLR guaranteed that my code would work anywhere the .NET framework was installed (no more checking for and installing COM DLLs). Anyone who distributed any significant software back then knew how much this kind of promise would resonate with frustrated operations teams everywhere. Your chosen language (C# or Visual Basic) compiler would  convert your code to the Common Intermediate Language (CIL), and the Common Language Runtime (CLR) would convert that into native code. Done! your code works everywhere … well … everywhere Windows runs.

At the time I was a Visual Basic programmer so the secondary appeal was that I could “upgrade” to VB.NET and work in concert with C# developers and from there make a clean break into C#. As it happens the switch to C# was not nearly as problematic as I had imagined and so I go the chance to jump ship. So while the idea of supporting multiple languages with a particular product was a much lauded benefit most folks opted to move to C# anyway. Back then Visual Basic never quite sat right with me, it reminded me of the opening conversation between Morpheus and Neo in the Matrix.

What you know you can't explain, but you feel it. You've felt it your entire life, that there's something wrong with the world. You don't know what it is, but it's there, like a splinter in your mind, driving you mad. It is this feeling that has brought you to me. Do you know what I'm talking about?  - Morpheus

Yes I do Morpheus, you are talking about Visual Basic 6!

Fast forward these ten plus years and we have  significantly more kinds of operating systems, devices and languages that drive and, in some cases, inhibit our software productivity. So today I wanted to talk about the approaches you might want to consider for being productive across an ever increasing range of platforms.

About 3 years ago I started to notice that my main programming skills (C#) were not stretching as effectively into a new breed of products targeted at the everyday consumer (as opposed to enterprise consumers). With the ascendency of iOS and Android the skills I honed over years in Visual Studio were only marginally helpful and these devices seem to be springing up everywhere. So in contradiction to the CIL and CLR approach, the idea of becoming a true polyglot appears to be more important than ever.

The Polyglot

So if you are of the iOS persuasion then your approach would inevitably turn to the  Xcode IDE and Objective-c (now Swift of course) on a Mac. Having never owned a Mac (much to the chagrin of my better half) I have been left out of any serious iOS development thus far. In general the IDE has witnessed a slow hard climb into the light but the most recent updates have some decent improvements, including the live rendering at design time (critical for my work flow).

xcode

The recommended approach for Android is the Eclipse IDE in combination with Java (it also has plugins for C/C++, PHP and others) on Windows. For me the Eclipse IDE has many more parallels to Visual Studio than does the Xcode IDE. Additionally Eclipse has been around since 2004 so many of the features I expect within an enterprise level IDE are readily available.

eclipse

Java is relatively easy for me to read, but what is even more familiar is the use of Android XML, it is appropriately different to XAML, but as long as you are comfortable with general XML schema you can quite confidently make changes inline if necessary.

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TextView android:id="@+id/text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Hello World!" />
<Button android:id="@+id/button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Hello World!" />
</LinearLayout>

Aside: I do find it fascinating that most larger companies (like mine) appear to prefer the notion of developer specialists which runs counter to the prevailing Sprint and DevOps influence. I wonder which approach will win out?

New Portability features in Visual Studio

The Visual Studio team is doing an increasingly brilliant job of embracing the diversity of the programming world especially as it relates to open source and the web. What I am finding more remarkable is the embrace of other platforms, for example, the new .NET Portability Analyzer helps you determine how flexible your application is across a variety of platforms (including Xamarin). I fully expect Xbox will be added to this list in the very near future to and thereby support a truly universal windows app concept. The .NET API Port team is eager for your feedback!

dotnetportability

This is an interesting first step and I am hopeful that this is a positive harbinger of collaborations to come.

Ultimate Portability in Xamarin

I have a growing appreciation for folks who write brilliant software and further have the discipline to write text to explain concepts clearly and articulately. In my chosen profession then, I hold Charles Petzold in the highest regard. I have read most of his books and follow his blog with some interest, while he blogs more about music these days it is still generally fascinating stuff (he actually encouraged folks to go see Atlanta Orchestra while at a Microsoft conference, it was quite brilliant!).

His seminal book, Programming Windows, laid the foundation for me and many Windows programmers of my generation. So of course I was then pleasantly surprised to see him working full time for the Xamarin team, writing a new book (“Creating Mobile Apps with Xamarin.Forms”). For me this upcoming book is like a bellwether for future mobile development practices for traditional Windows developers. I was initially skeptical that you could make compelling products across multiple platforms from a single IDE but I am seeing more and more evidence that this approach is both practical and indeed optimal.

XamarinDeviceSupport

So what is your approach? Are you conversant in multiple languages and multiple IDEs? Or are you relying on Xamarin and C# as *the* approach?