Monday, August 27, 2007

R.I.P. Vista

Well, I've finally done it.  I've gotten so tired of Windows Vista that I've decided to scrap it in favor of XP.  I purchased a copy of XP Pro that should be here in the next week and I can't wait to format Vista!

Problems I had with Vista:

  1. Excruciatingly slow on simple tasks such as moving/deleting files (hours to delete a 100 MB file)
  2. Entire OS as a whole looks good, but the theme makes things hard to read, etc.  There is too much white, everything is white and white. 
  3. Windows classic theme looks like a cartoon.
  4. Several times I shut the computer down only wake up the next morning and find that vista is still "logging off"
  5. Just an overall pause in starting ANYTHING.  It would sometimes take 3-5 minutes to open FireFox.
  6. Don't even get me started on using Visual Studio 2005 on Vista...

Look, I'm a computer programmer, and early adapter, and open minded and smart human being, but there's only so much I can take!!  I am in no way opposed to change, in fact I usually love it (I love Office 2007 for instance) but Vista is bad bits.  Hopefully SP1 will fix most of the issues and if so, maybe I'll give it another try.  For now I'm going to go back to the greatest operating system ever made, Windows XP Professional.

Tuesday, August 14, 2007

Work Smarder (Smarter-not-Harder)

I am a developer.  When it comes to Visual Basic, C#, or even Perl, I am the man to call.  The biggest problem with being a developer though is that I am not a designer!  I know what looks good when I see it, but I am sorely lacking the ability to make the transformation from <ugh> to <wow>

Thankfully though, there are several places that help me work smarder.  When I'm creating a web application, the first thing I do is start browsing the interweb for Open Source Web Designs:

  1. http://www.freecsstemplates.org
  2. http://www.odwd.org
  3. http://www.openwebdesigns.org
  4. http://www.openwebdesign.org

I can ALWAYS (yes, I said always, not almost always, but always) find a template that will get my project kick-started at the very least.  In fact, I have the RSS feeds of all of the above sites on my FireFox toolbar and I check them every day!  I have a bookmark folder of nothing but open web designs that I like.

When I started forming an idea of a Task List web app I was thinking about building, the first thing I did is start rummaging through my favorite design bookmarks and came up with this baby

Using the MasterPage features of ASP.NET 2.0 and an open source web design, I'm 30-60 minutes away from a design that KAFF's (Kicks Ass For Free).

If you're interested in hearing more about how to turn an open source template into an ASP.NET 2.0 Master Page, shoot me an email or leave a comment on this story.

Monday, August 13, 2007

How to use a ToolTip to extend a TextBox

I'm working on a windows app at the moment and (thankfully) I'm heading down the home stretch.  I'm now at the point that end users are testing the app and requesting changes. 

The app is going to take care of customer maintenance/promotions for our company so it has all of the usual things, Names, Addresses, Email Addressees, you get the point.  To make a long story short, the users want the TextBox where they type in an Email Address to extend while they are typing to show the entire email address, no matter how long it is. 

"Think about in Excel, when you're typing in a cell and what you're typing in is longer than the width of a cell, the cell just extends until you tab out of it."

I thought that between all of the .NET source available on the interwebs, the .NET Framework, and the Infragistics controls we use that I would be able to find this functionality somewhere.  Well, I was wrong!

 

The solution I came up with was a simple one though, I would just use the ToolTip control provided with .NET 2.0 to display a ToolTip directly under the TextBox that would dynamically change while the user was typing.  So that's what I did, and here's how I did it:

 

 

On the TextBox.Enter event

    // Shows the ToolTip if the TextBox is not empty
searchToolTip.Show(this.txtEmail.Text, this, 115, 395);

On the TextBox.KeyPress event

    if (char.IsLetterOrDigit((char)e.KeyChar) ||
char.IsPunctuation((char)e.KeyChar))
{
// Show the ToolTip with the next TextBox.Text
searchToolTip.Show(txtEmail.Text + e.KeyChar.ToString(),
this, 115, 395);
}
else
{
// Show the Tooltip without the KeyChar added
// if a garbage key is pressed
searchToolTip.Show(txtEmail.Text,
this, 115, 395);
}

And finally, on the TextBox.Leave event

    //Hide the tooltip
searchToolTip.Show("", this,
Screen.PrimaryScreen.Bounds.Right,
Screen.PrimaryScreen.Bounds.Bottom);

Friday, August 3, 2007

Venting Frustrations

image I think probably the #1 problem that computer programmers have is the fact that the people (for the most part) that will be using your application are not computer programmers.  You go through all the trouble of creating shortcut keys, making sure the tab order is perfect, and adding that sweet collapse animation to your application only to have it pushed out to some middle-aged women running at 800x600 resolution who think shortcut keys are what the black ones on the piano are called.

The problem: you are writing this program for them to use!  You have to make them happy, no matter how much it means ripping your application apart and starting over.  Programmers who code internal apps for use within the company, who are your customers?  Your co-workers.  You should write applications that the 40-something's two floors above you running 800x600 on a 17" monitor can be happy about using. 

It's not always easy.  You get the perfect color palette and everything looks great until your demo when you get a "There's too much blue, you need bold colors that will stand out like red and yellow!"  Honestly, red and yellow.  They said that.  Throw on the headphones, kick your iPod on the Jack Johnson/John Mayer/Jason Mraz playlist and get to coding my friend.  You love a challenge and that's why you started coding in the first place.  Bring it back to Windows 98 style baby, the customer is always right!

            if (DateTime.Now.DayOfWeek == DayOfWeek.Friday)
{
MessageBox.Show("Almost there...");
}

del.icio.us tags: ,