I hate seeing code mixed with markup. Seeing a template page with <% if(show) { %> makes me want to claw my eyes out. Seeing String htmlTitle = "<h1>" + title + "</h1>" causes me to vomit up a little something in my throat. Mixing code with markup is not a...
Today I needed to load in an XML file into memory for later use. At first I was going to use the XmlDocument library (old habits die hard), but later switched over to the XDocument library. Why, not because one is better (ok, so I think that XDocument is better, but not the point here), but because...
If you happen to be using Linq2Sql and are also someone who tests, I have something for you. You can use Linq's DataContext to create your database and then populate it with test data prior to each test run. Note that you can do this same thing when using other OR/M tools such as NHIbernate...
Originally this series was meant to be titled 'Any thing you can do I can do better', but to be honest after writing the Xml/XPath examples I realized the XLinq is really no better per say than Xml/XPath. However, what XLinq does bring to the table that Xml/XPath does not: Does not need...
Originally this series was meant to be titled 'Any thing you can do I can do better', but to be honest after writing the Xml/XPath examples I realized the XLinq is really no better per say than Xml/XPath. However, what XLinq does bring to the table that Xml/XPath does not: Does not need...