Friday, April 21, 2017

My Quest for .NET Literacy


I have flirted with C# and ASP.NET over the years, but I've finally reached a point where I want to jump into the stack with both feet. I will be documenting my journey here and on GitHub.


My first web development job started with ASP Classic back in 2000, thanks to a friend with an ambitious start-up. Unfortunately, the start-up went belly-up after a year, so I went back to a previous employer in a new role, as their web developer. Macromedia ColdFusion already had a foothold there. My boss was open to ASP, but I soon realized that rewriting their existing code would be a colossal waste of time with little net gain. Besides, ColdFusion was very easy to pick up. Look at query syntax...

In ASP Classic:

sSQL = "SELECT foo FROM bar"
sConnString="Provider=SQLOLEDB;Server=SOMESERVER\SQL2008R2;Database=WebDB;Uid=sa; Pwd=Password;"

Set connection = Server.CreateObject("ADODB.Connection")

...and in ColdFusion:

<cfquery datasource="datasource" name="someQuery" timeout="60">

On learning an equally simple CFMAIL tag replaced the rats nest of CDONTS code, I was hooked. Thus started a now 16 year career in web development, rooted in ColdFusion.

So, Why ASP.NET and C#?

In a nutshell, employability. ColdFusion jobs are harder and harder to find these days. We are fast becoming the COBOL programmers of the 21st Century.

While ColdFusion 2016 is nice enough to work with, the Microsoft stack is light-years ahead... Visual Studio vs Eclipse/ColdFusion Builder, .NET libraries vs CF libraries, Entity Framework vs roll-your-own service/gateway patterns, MVC vs FW1, ColdBox, ColdSpring, yadda-yadda... there is just no comparison. Add to that the quality and quantity of .NET online instructional resources, experts, and open source projects... The whole ecosystem is so much healthier.

To be fair, ColdFusion is far easier for a novice to pick up, thanks to its loose syntax and curious occasionally-typed variables, but these same features also lead to bad habits that newbies should avoid. Forget to define your function parameters? Meh. Its CF. You don't have to. (Good luck debugging THAT code.) Didn't scope your variable? CF will take a shot at finding it ( cycling through every scope. Woohoo! Efficiency!) SO... While it is easier, I can't recommend ColdFusion as a good starting point for serious developers. You're far better off starting with a more rigid, structured language and picking up CF afterward if you need it for a particular job.


C# and ASP.NET literacy.

"Come again?"
To be clear, this won't be ASP.NET and C# for ColdFusion developers. This is just me eating the .NET elephant one bite at a time. Also, while individual posts may be useful for beginners, don't expect that by following each post from beginning to end, you will reach the same target that I do. I have a lot of experience and will be skipping over some fundamentals. The upcoming blog posts will simply be a running commentary as I learn. I have found that explaining concepts as I learn them helps cement them in place. If my posts happen to help new coders come to terms with these new concepts, then its wins all around.

Brien Malone

1 comment:

  1. I'll follow your journey with interest. I spent a lot of time in .NET and thought it was very cool, but I never trusted myself in that, or any other, PC environment enough to commit anything to production. My programmers did, however.

    I knew one guy who used ColdFusion for years, or maybe I should say, years ago. He was very enthusiastic about it. I haven't heard from him for a couple of decades and have no idea what he's doing now.

    I'm now writing a memoir of my career in computers. It's approaching book length, so if it ever ends, it will complement yours by showing what the dark ages were really all about.