Ben Griswold on July 9th, 2008

I am releasing/distributing a Windows application and service in a couple weeks.  Both application use the .NET 3.5 Framework and are wrapped up in a custom installer.  Rather than having my installer prompt the user to download the .NET 3.5 framework installer, I’m packaging it up with my setup program.  Very simply, I check to [...]

Continue reading about Using .NET 3.5 Client Profile (BETA)

Ben Griswold on July 8th, 2008

I’m a fan of Pandora Radio.  I really love the product and I complete dig the simplicity and slickness of their Adobe Flash GUI…with one exception.  I have an issue with the play/pause control.  Pandora has chosen to recognize the current state of a song (playing, paused) by highlighting the associated button.  The image to [...]

Continue reading about Pandora Radio and User Interaction

Ben Griswold on July 3rd, 2008

I have collected a reasonably good size library of C# helper files over the years.  The EncryptionHelper below is one of many which I plan to share. using System; using System.Security.Cryptography; using System.Text; namespace Common { public static class EncryptionHelper { private const string cryptoKey = “cryptoKey”; // The Initialization Vector for the DES encryption [...]

Continue reading about C# Encryption / Decryption Helper Class

Ben Griswold on July 2nd, 2008

I am not a CSS expert, but the following technique can be used to easily apply an image next to virtually any link.  First you need to define your CSS class which sets the background to a referenced image.  .icon-cancel { background: url(../images/icons/cancel.gif) no-repeat left top; display:inline; padding-left:18px; margin-left: 10px; padding-right:10px; } Once defined, assign [...]

Continue reading about LinkButton Image

Ben Griswold on July 1st, 2008

In the same vein as my last post on how to programmatically update a service startup type, here’s how one might determine if a service is currently stopped in C#: using System.Management; /// <summary> /// This routine checks if the provided service is stopped. /// </summary> /// <param name=”serviceName”>Name of the service to be checked</param> [...]

Continue reading about Check Status of Windows Service

Ben Griswold on July 1st, 2008

For the past six years I’ve been focused on web applications.  My current project, however, has me splitting time between the web and the desktop.  Today, I needed to programmatically toggle the Startup Type of my service between Manual and Automatic based on business conditions.   Here’s how I did it: /// <summary> /// This routine [...]

Continue reading about Update Service Startup Type