If You Don’t C#…
May 7, 2010
Programmatically Speaking
It’s been a right long time since I’ve written anything. There are reasons for that, but they’re by and large irrelevant for our purposes, here. I’ve been here and there and everywhere and what has finally happened is that I’m trying to get back into the IT world doing what I’ve done for the past 15 or so years, writing code. The catch? I’m an old goat in this world: no one REALLY wants a Visual Basic 6.0 programmer. Really. If they do, they want you inasmuch as you know VB6.0 in order to convert apps over to .NET, be it VB.Net, ASP.Net or C#.Net. I will admit — I hadn’t really worked in C# in a capacity that I would call “professional,” or even “mildly amateurish” at the time I started looking. That said, the learning curve — which felt daunting when using VisualStudio 2002, 2003 and 2005 — was almost nonexistent using VS2008. It just made sense.
Send in the Clones
I started looking at resumes, looking at source code of other folks and started trying to figure out how to ramp my skill up to what most companies would want — and fast! You know what I found? Imitation is irritating and just trying to mimic what’s out there will do nothing for you, especially if you’re like me and see programming as creating, an outlet by which to bend the computer to your will in order to produce something beautiful. Well, OK, sometimes it doesn’t come out beautiful, but you know what I mean. Order from disorder. Taking what the corporate world seems to call SDLC and making it a birthing process.
Head First
So, I knew I needed to learn C#, immediately, and get as experienced as possible in as short a time as possible. It sounds a lot like drinking your tea before it can steep, doesn’t it? Well, I decided to create. I have two projects that I am currently working on, now, that have pushed my brain a LOT and I’ve been getting VERY familiar with the ins and outs of C# and the .Net framework. They’re both niche programs, but in their nichiness offered the ability to deal with things that I hadn’t often had crop up in the “real” world in exactly the same way, so it is experience and it’s head first.
The first project is RuneSong. It’s probably what you think, if you think it’s a program that allows the user to do single, 3, 5, 9 and 24-rune castings. Sounds simple, right? Bunches of random numbers and displaying them to the user, right? Not exactly. I tell you what — everything was pretty simple until I had to generate random numbers between 1 and 24 and have 24 unique numbers. My first attempt was inelegant, at best, and horrific, at worst. When it would get to runes 23 and 24 it would basically generate a random number until it found one that wasn’t already in the list. Yes, it probably would have gone forever if I had let it. No, this isn’t very useful. After a few of hours racking my brain and ALMOST having it — using linked lists, I nailed it, EXCEPT that the 24th number was always 1. D’oh. While I can’t give out any trade secrets, I will say that a self-reducing array did the trick.
The second project is the one getting most of the attention, right now, and that is the application I’m writing for Moonshadow Gardens daylily farm. The app will allow for adding/removing/updating daylilies in both the main “inventory” and also the catalog. There are some other business related modules involved and, finally, a quick and easy way to update the website from the app. It’s pretty ambitious, but I’ve learned a LOT about C# and how it works with things I used to take for granted in VB6, like control arrays, and that’s cool — the things that were daunting are becoming almost second nature. I’ve also learned how it interacts with not only the SQLServer2005 that ships with VS2008, but also MySQL and am making the app so that it can use either of those two and, also, Oracle, should there be a desire to do so.
MySQL?
During a technical interview, I was asked why I chose to use MySQL for the application rather that the bundled SQLServer. I’ll tell you what I told them… Original development took place on a PIII/730 with 512MB RAM. Let me put it this way — when it comes to low overhead speed, MySQL ran circles around SQLServer for what I was doing. Now, working on a 3GHz P4 with 2GB RAM, it’s a push, which is why I’m putting the additional modifications to utilize SQLServer and even Oracle, for the intrepid. I drew the line at SyBase and Informix simply because I was running out of HD space for all these monster dbs and the overhead of 5 RDBMS was more than a little daunting.
Cross-stitch…
OK, in learning C#, I also learned that VS2008 was a bit of a bloated beast and on the original development PC wouldn’t load if anything else was loaded (like a browser…). This is bad. It was at this point that I discovered two alternatives to VS2008: MonoDevelop and #Develop. I would use MonoDevelop for everything as it supports cross-platform compilation which allows for Win32 and Linux binaries to be generated from the same code. Like I said, I would, were it not for the GUI creation tool; it’s not where I need it to be for true rapid application development, since it’s not what I would call intuitive and #Develop and VS2008 handle it much better.
So, I use #Develop (SharpDevelop, if you prefer…I don’t…) almost exclusively, jumping into VS2008 every so often to uncheck some flag that got set during initial creation that isn’t given an option to even select in either of the other two. I load the source into MonoDevelop to churn out linux binaries, but that’s about the only time I work in it. I like the look, feel and behavior of #Develop much better than the other two — and it’s a) free and b) open source. The only drawback that I’ve found, thus far, is that it doesn’t like the Oracle .Net components…then again, neither does VS2008…
In conclusion — it’s been gratifying getting my skill level to where my VB skills were after 15 years. At some point, the programs may even be fit for mass consumption…of course, as much of a perfectionist as I am, they’ll probably be ready long before I’m ready to let them go…