Keith Barrows

Musings on Microsoft Technologies and other technical things

  • Utilizing Generics to make a Class structure more mutable…

    While the ASP.NET GridView control supports automatic paging I found it faster to use custom paging in several situations.  I found myself rewriting the same code over and over just to add the basic sorting capabilities to an ASP.NET GridView object.  So today I took just a little bit of time to encapsulate it all into a Class I can use and reuse on any page with a GridView.  In fact, it will probably take longer to write this blog entry than it took to encapsulate the functionality.

  • Extension Methods make life easier (C#)

    I use extension methods when I remember they exist.  I started getting tired of writing code to check strings for Null, Empty, Equal before using a database column when I remembered Extension Methods are there to make life easier!  Some great articles/blog entries on it can be found at:

  • Using LINQ to SQL Classes in VS2005

    I am having a devil of a time setting up LINQ for SQL in VS2005.  I have fx3.5 setup, have installed fx3.5SP1, etc, etc.  What googling has shown me is when I want to add a LINQ to SQL Classes item to my project I should see something like the first image.  Instead, what I am seeing is the second image.

  • Tidbits

    From time to time I get a slew of links that may/should be useful to others than just myself. The quotes are from these web pages and are not of my manufacture.

  • Missed my High School Reunion :(

    Wish I had thought to google for this.  Another classmate just left me a message on MySpace and the link to my HS Reunion site.  <sigh/>

    With all of this technology at hand it is still hard to know when periodic events like this happen.  How does everyone else stay abreast of events like this?
    Cross posted from my blog at http://schema.sol3.net/kbarrows

  • Loading XML with accented characters breaks System.XmlDocument.Load()

    It took me a bit of time but I finally found a solution for loading a XML file that has accented characters (like áéíóúâä) into a UTF-8 format.  I'm loading data for a client and it ended up having a name in it with an accented e character.  For the first time on this project System.XmlDocument.Load() was blowing up.  With a lot of Googling I finally found a link that gave me, what I hope, is the solution for this problem.  For now it is working so I'll go with it.  The link to the article I found is in the code sample below as well as the image to the left.  The magic happens by reading in while enforcing a double-byte encoding then saving out in an encoding that gives the visual representation we, in the US, would expect.

  • Managed Extensibility Framework (MEF) is on CodePlex

    The Managed Extensibility Framework (MEF) is a new library in .NET that enables greater reuse of applications and components. Using MEF, .NET applications can make the shift from being statically compiled to dynamically composed. If you are building extensible applications, extensible frameworks and application extensions, then MEF is for you.