# Friday, December 03, 2004

[UPDATE: Added new section for Andrew Bird lyrics.]

As a follow-up to the posting about "bad" music, I thought it an appropriate time to share with my few readers something which I have been intending to share for a while now; Andrew Bird. Rather, the music of Andrew Bird.

Andrew Bird has been playing violin since he was a young lad (four years old). Years ago he appeared on a few Squirrel Nut Zipper songs, most notably the song "The Ghost of Stephen Foster" (audio excerpt courtesy of Amazon.com). Although Bird enjoyed playing with the SNZ, he didn't feel he would be happy staying on as an official member; he went on to form Andrew Bird's Bowl of Fire. The music they put out on their first couple of albums ("Thrills" and "Oh! The Gradeur") was pigeonholed by many as belonging to the "swing" genre.

With The Swimming Hour, and more recently Weather Systems, Bird left behind the swing genre and its ilk almost completely, instead producing an album that, as a whole, cannot be easily described (which is why I will not make any certain-to-fail attempts at doing so here). Suffice it to say that Andrew is not only an accomplished violin player, but an awesome lyricist and performer as well, spending much of the last 2 years touring alone and utilizing some simple looping devices to essentially function as a one-man band. You must see this to believe and appreciate it, and thankfully, you can see such a performance courtesy of the WoodSongs Old Time Radio Hour (this video (156MB!!!) at 23:05, 27:30 (the best place to start), 46:10, and and encore at 1:08:10 (this is my fave part of the performance, simply amazing) - I would download the entire thing before watching so you can cue up those times rather than wait through the entire streaming video (and have to watch The Crash Test Dummies)).

Simply put, I have not been this excited about music in half a decade. For music to *really* get ahold of me, the lyrics as well as the sound must be worthy of attention. Case in point are the lyrics to 11:11, a song about fate/destiny - in an interview Bird said that this song's lyrics were somewhat based on some true stories, one in particular about a young boy watching as his brother was shot in a drive-by shooting while drinking a glass of milk near a window, another about a woman killed by a piece of a window pane being carried by the wind:

Standing on the corner
Plastic cup in her hand
Standing on the corner
Saving for some gin
You don't need to ask where she's been or what's up
She'll gladly tell you all about the life she had
Before she had the cup

Standing by the window
Glass of milk in his hand
What could I have done what could I have said
Broken glass spilled milk lying on the floor looking dead

Window pain
Cutting through the rain looks so easy
Frame by frame
Looking for a name to claim on a breezy afternoon
And the ends coming soon

So many people hold a cup
So many die drinking milk in front of a window
I once knew a woman who got in the way
Of the intentions of a windy day
Don't hold a cup in any season
Don't make me choose between rhyme or reason
Don't drink that milk in front of that window
You might as well blame it on the will that the wind chose

You really should listen to the song and follow along in the lyrics to get the full effect. I think this song is one of my faves, mainly for the lyrics and the way the music is arranged. Two other favorites from The Swimming Hour are Case in Point and Way Out West. Both are worth your time. From the newer album, Weather Systems, Lull is probably my favorite, Nora O'Connor's voice rounding out Andrew's. That song has the sweetest sound - it is like audio Valium . . . so relaxing.

Andrew's next album is due out in February of 2005. You can get other albums and more information at his official website.

DISCLAIMER: This is in no way meant to serve as an exhaustive reference essay or history of Andrew Bird, so please don't construe it as such; and I make no promise that everything here is accurate, though I *am* rather anal about getting details as correct as I can.

Kick It on DotNetKicks.com

posted on Friday, December 03, 2004 6:34:50 AM (Mountain Standard Time, UTC-07:00)  #    Comments [0]
# Thursday, December 02, 2004

Today I was shown something that I think is relatively hilarious. You Have Bad Taste in Music showcases videos of some guy going to music concerts/shows and basically berating the people standing in line, telling them that they "have bad taste music." To understand just how funny it is, you have to see it yourself.

Although none of the videos show it happening, I cannot help but wonder if serious bodily harm ever comes to this fellow (in one of the videos, someone seems to intimate that they are going to beat him up, but it doesn't happen). In some of the situations, he simply starts telling the people that they have bad taste, et al, but in others he gets his victims involved before they know what is going on, resulting in these people looking really stupid for having participated.

The main message of YHBTM is that the influence of radio and television have caused people to be indiscriminate in their choice of music to enjoy. I don't disagree with this at all. Music is sold more on image now than ever, and if you don't have the media and pop culture behind you and your music, you are certainly doomed to sell less records than the mediocrity which passes for superior music these days. According to the spokesman for YHBTM, there are three steps to beginning your journey away from bad music:

  1. Do not attend "this" concert (the concert at which he is making these statements).
  2. Stop listening to bad music (usually specified as the band putting on the given concert).
  3. Turn off your radio and TV (because these feed your incorrect ideas on what constitutes "good" music).

By all means, watch all of the videos on this site. It will take you an hour or so, but it will be worth every minute. But don't stop there; you too must become part of the movement, and follow those three steps. One thing that I am very curious about . . . what kind of music does this guy listen to, and what in my personal music library would he find offensive. Maybe I can send him a list and have him indicate. Not that it would prevent me from listening to what I like . . . :P

Kick It on DotNetKicks.com

posted on Thursday, December 02, 2004 4:19:36 AM (Mountain Standard Time, UTC-07:00)  #    Comments [1]
# Thursday, November 18, 2004

I had heard this was going to happen for a while, but didn't really expect it - my Hotmail email accounts have been upgraded to 250 MB of space (up from a measly 2MB). w00t!

Although I don't really use my Hotmail accounts all that much (one is basically a spam account that I only keep for use with website accounts and mailing lists, etc. and the other is family and friends only (utilizes a 'safe list')), the extra space means I don't have to worry as much about the box filling up so fast and then bouncing communiqués which may be important. .

Kick It on DotNetKicks.com

posted on Thursday, November 18, 2004 10:16:38 PM (Mountain Standard Time, UTC-07:00)  #    Comments [0]
# Thursday, October 14, 2004

How did I ever live without this. I already love using it so much; I have only been running it for an hour! Google keeps on doing great things, it is hard to imagine life without it.

Kick It on DotNetKicks.com

posted on Thursday, October 14, 2004 7:57:17 PM (Mountain Daylight Time, UTC-06:00)  #    Comments [0]
# Friday, September 24, 2004

The mouse arrived today, and a worthy companion has been found and purchased (getting it brand new for $1100 cheaper than retail, thankfully). Soon (within a week or so), they will join together to create sweet sounds (or code, if you want to be technical). This will be a nice development machine with which to craft the code of my dreams.

I am starting a new job on Monday, working for TEK Systems (as a W-2 employee!) on a contract in downtown Salt Lake. I am leaving behind an independent contract job (as a 1099 contractor . . . yuck) which was fun for a while.

Okay, I am rambling now and really need to get back to installing this beautiful mouse on my current machine, so that I can break it in while it is waiting for its future partner!

Kick It on DotNetKicks.com

posted on Friday, September 24, 2004 12:49:07 AM (Mountain Daylight Time, UTC-06:00)  #    Comments [2]
# Wednesday, September 22, 2004

Behold this beautiful manifestation of engineering prowess:


What is it? Well, it is none other than the latest and greatest
Bluetooth-utilizing mouse from the people in Redmond. It will be arriving at my home, in all of its unabashed glory, in the next 48 hours, where it will await a worthy companion which I am currently in the process of selecting. Together, they (along with one enhancement and another) will enable the user to have what he considers to be the ultimate setup. No wires attached. Oh yes, what fun will be had!
Kick It on DotNetKicks.com

posted on Wednesday, September 22, 2004 6:04:46 PM (Mountain Daylight Time, UTC-06:00)  #    Comments [0]

In addition to code generation, object/relational mapping is a subject that makes me feel all warm and fuzzy inside. Although I have not been able to use an O/R Mapper as of yet on any projects (not because of lack of desire, only because of lack of support for doing so among the developers I have worked with), I have read about and wanted to get involved with them for probably a year and a half now.

After reading Paul Wilson's rant (via Steve) regarding mappers, I think I am going to finally force myself to sit down and implement a project using one.

As with code gen, O/R mapping is something which, unfortunately (or fortunately, depending on how you look at it (I use code gen, for example, so I can often move quicker on a given project than unbelievers (read: I can do it cheaper))) receives little attention. Funny thing is that people in the J2EE world are familiar with and utilize this pattern, and have for quite a while (Hibernate, SimpleORM). As seems typical with those in the Microsoft camp, slow adoption is prevalent, and amazingly few people really even know what it is or why it may be useful.

Having long been a user of his free DAL generator, LLBLGen (going on 2 years now), Bouma's LLBLGen Pro appeals to me simply because I have watched Frans posts in the Architecture forum at www.asp.net over the last couple of years, and I like his ideas and agree with his opinions (though I will admit my opinions are not as well-informed as his are!).

Until I feel compelled to spend the money and buy LLBLGen Pro, I will give Paul's mapper a try at the much lower cost of $50 (after trying the demo of course). Unfortunately, my anticipation of seeing ObjectSpaces was ruined by Microsoft's inevitable delay thereof. Oh well, what can you do?

Kick It on DotNetKicks.com

posted on Wednesday, September 22, 2004 6:37:03 AM (Mountain Daylight Time, UTC-06:00)  #    Comments [1]
# Thursday, August 26, 2004

This is more of a note to myself, nothing too interesting. Simply some links to interesting articles on patterns and such:
Enterprise Development Patterns
Patterns & Practices
Improving .NET Application Performance and Scalability

 

Kick It on DotNetKicks.com

posted on Thursday, August 26, 2004 6:20:15 AM (Mountain Daylight Time, UTC-06:00)  #    Comments [0]
# Tuesday, August 24, 2004

I do a lot of ASP.NET development, but I don't have many reasons to mess around much with writing custom web controls and the like (I use quite a number of 3rd party controls as well as the .NET framework controls). I write user controls quite a bit, but have not had much time to look into compiled controls. Someday maybe I will get that chance. I did create one control that is not very exciting but has been useful for me, and herein I will describe it.

First, let me tell you about the scenario that brings me to this point. I use the DropDownList quite a bit. The usual thing I do is bind a collection to it and have AutoPostBack set to true so that I can then do some other thing with the selected value (drilling down into nested data, for example).

For an example, let's say I am binding a list of names to this list. When the user sees this list, the first member of the collection shows up already selected in the dropdownlist. This means that the only way I am going to get autopostback to work on the control is if I select any name other than that one. But what if I want to choose that one? The obvious answer is to place something in that first position. Here is what I usually do:

ClientDDL.DataSource = UserManager.GetAll();
ClientDDL.DataTextField = "Name";
ClientDDL.DataValueField = "UserID";
ClientDDL.DataBind();
ClientDDL.Items.Insert(0, new ListItem("Choose . . .", "Choose . . ."));

Then, in the handler for the SelectedIndexChanged event, I use the selected value to do something (constrain another list maybe) and then do this:

if(ClientDDL.Items[0].Value == "Choose . . .") ClientDDL.Items.RemoveAt(0);

That effecitively gets rid of that first option (the "Choose . . .") so that 1) no one can choose that option and 2) because there is no longer a need for it.

This is a recurring pattern, and I knew I could encapsulate this into a derived version of this control. So, I wrote the following class:

public class MyDropDownList : System.Web.UI.WebControls.DropDownList
{
   protected override void
OnLoad(EventArgs e)
   {
      base
.OnLoad (e);
      if(!this
.Page.IsPostBack)
      {
         this.Items.Insert(0, new ListItem("Choose . . .", "Choose . . ."
));
      }
   }
   protected override void
OnSelectedIndexChanged(EventArgs e)
   {
      base
.OnSelectedIndexChanged (e);
      if(this.Items[0].Value == "Choose . . .") this
.Items.RemoveAt(0);
   }
}

I compiled this and added the DLL to my toolbox. Now, all I do is drag that to the design surface and bind to it like so:

ClientDDL.DataSource = UserManager.GetAll();
ClientDDL.DataTextField = "Name";
ClientDDL.DataValueField = "UserID";
ClientDDL.DataBind();

So, I don't have to think about this "Choose . . . " line anymore, it is all taken care of automagically for me because I have encapsulated it in that derived control. I don't think this is necessarily the ideal way to do this, but it does seem to work just fine (I just did this moments ago, so maybe further testing will reveal some flaw or another). Again, for what I am doing this is perfect. It may not be the ideal control for other uses of a dropdownlist.

Kick It on DotNetKicks.com

posted on Tuesday, August 24, 2004 6:35:38 AM (Mountain Daylight Time, UTC-06:00)  #    Comments [0]
# Sunday, August 22, 2004

For one of the innumerable personal apps I am writing, I decided to store some values in session variables. However, I loathe the syntax for both getting and setting such variables:

Session["UserID"] = userID;

GetSomeData(Convert.ToInt16(Session["UserID"]));

Yuck. Why? The literal strings. I want strongly-typed stuff. I don't want to have the opportunity to accidentally type Session["UsrID"] and deal with resulting issues (I know, it is not that big of a deal, but you know), I want design-time features like code completion/Intellisense. So, at first my idea was to create an enum containing all of the session variables I would use for the app, like so:

public enum SessionVariables
{
   UserID, ClientID, etc.
}

And then I would do this:

Session[SessionVariables.UserID.ToString()] = userID;

That gave me Intellisense and strong typing (more so than a string literal), reducing the chance that something would be typed incorrectly.

But I still don't like the whole "Session[...]" thing. In order to understand my solution, I first must say that I have created a base class for my site's pages. Every ASP.NET page must inherit from the System.Web.UI.Page class at some point, either directly or as a result of a deeper inheritance structure, and I have an intermediate class which inherits from that class, and then all of my pages inherit from that derived class. So, the solution I came up with (I doubt this is in any way original, nor do I feel it is necessarily the ideal) involves creating properties on that base class. For example:

      public short User_UserID
      {
         set
         {
            Session["UserID"] = value;
         }
         get
         {
            return short.Parse(Session["UserID"].ToString());
         }
      }

As long as the page inherits from this intermediate base class instead of inheriting directly from the Page class, I have an easy, strongly-typed means of obtaining session variables without using the nasty syntax (I only need to use it in the property). So, now I can do this in my code-behind files:

User_UserID = userID;

GetSomeData(User_UserID);

Much sexier, and as an added bonus it abstracts WHERE I store the variables. So, if I want to, I can change that property in the base class so that instead of storing this value in session, I can store and retrieve it from a cookie should I desire to do so. (By the way, the reason I preface the property with the "User_" is because it makes it gives the property name a context, in this case these are properties associated with the current User. Also, one of the variables I am storing is a ClientID and that is already the name of a property of the Page class, so I have a collision there.)

Now, the question I have is this: is this a good way to accomplish this? It works, and I personally like it, but I have only thought it through for about 25 minutes.

Kick It on DotNetKicks.com

posted on Sunday, August 22, 2004 5:48:02 AM (Mountain Daylight Time, UTC-06:00)  #    Comments [2]