Wednesday, June 17, 2009

Standards

A smallish rant.

There are a lot of IT departments out there who have rigid standards on every aspect of application development. Coding standards, naming standards, etc etc.

Unfortunately, most shops have adopted standards as a means of control. Standards put in place for thus reason are often an actual impediment to the process of software design.

Standards should exist for one reason and one reason only - to ensure reproducible quality in work performed. A standard should not detract from the process but should enable a quality bar.

Tuesday, June 16, 2009

Hungarian Notation Diatribe

Sometimes I think coding standards are like fashion standards. Often, styles and notation are fawned all over one year and then criticized and passe the next.

The current target of the code fashion moguls is Hungarian notation. That's the idea of prefacing a variable or object name with the type of variable or object.

According to what I've researched, this is no longer needed because of Intellisense and cute little popups when you hover over code telling you all about the source of the entity. So, if you still use code conventions like btnEdit for an button with an Edit caption, you're some sort of reprobate.

Interestingly, Microsoft stays away from this debate in code samples. To them, a Label is forevermore Label1 in sample code. I can kind of understand that since being an ex-Softie I remember the reluctance to embrace 3rd party"standards".

Personally, I still use a type of Hungarian and probably always will. I don't see why it's such a bad thing to name a variable boolActive when it's a boolean flag or intChildren when it's an integer variable. Who does it hurt? It makes hard-printed code easier to read and it's easier to "digest" a block of code with its intent. The name of the variable or object has no impact on the stack or heap so what does it matter?

Stupid code standard dweebs. Get a real job.

Thursday, June 11, 2009

VS 2008 Bug with Master Pages

This is really dumb.....

I created a template that uses a Master Page with the skmmenu control - a very common menu control. With the template I have a default.aspx file that has nothing but a reference to the master page. Simple enough?

When creating a web site based on the template, I get an "Error Creating Control" when I look at default.aspx. However, if I first click on MasterPage and leave it in Source view and then click on default page, the menu bitmap is shown and no error.

Obviously, there's a synch issue here but even more obvious to me is that there are a group of testers in DevDiv at MS doing a shit job.

It's becoming increasingly apparent to me that MS is pushing out code that isn't being vetted fully and UX (docs, examples) can't keep up either. C'mon guys....all the cool tools in the world won't help us out here in the real world if you don't testit or document it.

Monday, June 08, 2009

ASP Menu Control and XMLDataSource

Alright, who's the dumbass who decided to make it so that it's very, very counterintuitive to create a horizontal menu strip using the ASP.Net Menu control with an XMLDataSource?

Beat my head against this one all day. It's easy in code, easy in markup, but only ONE root node from XML? Gimme a break.