Home ::  Admin

chris carter's web log

Step 1: Balsamiq Mockup

8:54 AM Thursday Oct 22, 2009 Comments: 0

Here's a quick stab at a hyperactive config editor using Balsamiq Mockups:

Matt Lauer "Helps" Unveil Windows On The Today, Sort Of

7:10 AM Thursday Oct 22, 2009 Comments: 0

Matt Lauer on the Today Show this morning had Steve Balmer on to talk about today's unveiling of the consumer version of Windows 7. Unfortunately, around minute 4:30 he starts talking about CEO salaries and bonus payouts. WTF? Seriously Matt, CEO salaries have exactly what to do with the release of Windows 7?

They also show the Sony VAIO L Series all-in-one touchscreen PC which looked pretty frickin cool, I'm diggin' those displays.

Windows 7 House Party Already Started!

7:25 PM Sunday Oct 18, 2009 Comments: 0

I've been running Windows 7 full time since the Beta was released. I signed up to host a house party for the Microsoft promo kicking off the October 22 consumer release of Windows 7. You receive a single license for Windows 7 Ultimate for hosting a house party so Friday night I decided to install the 64 bit edition on my Thinkpad. Everything rocks, here's what I have installed:

Hardware

Software

Windows 7 installed in about 12 minutes. Once the OS was installed, I updated the video and bios drivers only from Lenovo's site and that was it; audio, networking, and any other drivers were left out. The next steps involve getting the machine ready to develop .NET applications, so I start with Visual Studio 2008(and SP1), then SQL Server 2008(and SP1).

After the big pieces of software are installed, I continue with all of this:

I spent from Friday night until Saturday afternoon installing. I'm pleased to say, that given the above list of software, I have experienced zero issues. Windows 7. GET IT.

Pair<TFirst, TSecond>

6:0 AM Tuesday Oct 6, 2009 Comments: 0

I first used the Pair and Triplet classes while figuring out how to recreate dynamic ASP.NET WebForms controls. They came in pretty handy. Since then, generics came out and I created this(I'm sure I'm not alone):

/// <summary>
/// Responsible for representing two values of any type.
/// </summary>
/// <typeparam name="TFirst">The type of the first.</typeparam>
/// <typeparam name="TSecond">The type of the second.</typeparam>
public class Pair<TFirst, TSecond>{
    /// <summary>
    /// Gets or sets the first.
    /// </summary>
    /// <value>The first.</value>
    public TFirst First { get; set; }

    /// <summary>
    /// Gets or sets the second.
    /// </summary>
    /// <value>The second.</value>
    public TSecond Second { get; set; }

    /// <summary>
    /// Initializes a new instance of the <see cref="Pair&lt;TFirst, TSecond&gt;"/> class.
    /// </summary>
    public Pair() : this(default(TFirst), default(TSecond)) { }

    /// <summary>
    /// Initializes a new instance of the <see cref="Pair&lt;TFirst, TSecond&gt;"/> class.
    /// </summary>
    /// <param name="first">The first.</param>
    /// <param name="second">The second.</param>
    public Pair(TFirst first, TSecond second){
        this.First = first;
        this.Second = second;
    }
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33

Usage includes those times when you have the need for a structure to hold two simple values but you don't want to create a new class just for that. Say you want a dictionary where the key is an int and the value is that structure, you can do this with the Pair<TFirst, TSecond> class:

var dict = new Dictionary<int, Pair<string, string>>();
dict.Add(1, new Pair<string, string>("Carter", "Chris"));
dict.Add(2, new Pair<string, string>("Carter", "Emmitt"));
foreach(var kvp in dict){
    Console.WriteLine(kvp.Value.First + ", " + kvp.Value.Second);
}
1
2
3
4
5
6

and the output would be this:

Kind of a lame example but you get the idea. I had made a similar one for the Triplet class but that started looking a little messy so I put that on the back burner.

"No Task" Is Way Easier

6:31 PM Monday Oct 5, 2009 Comments: 0

So the other day I was getting caught up with zenhabits.com and came across this post. It totally made me stop in my tracks. Why? Because I started rewriting the blog again and kept running into motivational road blocks. I just didn't feel like rewriting it. So there it sat, the beginning of a rewrite and it never moved.

Then I read that article and it hit me like a brick. Stop rewriting this shit, go back to the version(that I'm posting with now) and get on with other stuff!

I feel like a huge weight has been lifted. Note to self: If you really don't need to do it, cross it off that list!