<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Spontaneous Publicity</title>
	<atom:link href="http://lfoust.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://lfoust.wordpress.com</link>
	<description>Blogs are the new phonebook</description>
	<lastBuildDate>Thu, 19 Jan 2012 15:19:51 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='lfoust.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Spontaneous Publicity</title>
		<link>http://lfoust.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://lfoust.wordpress.com/osd.xml" title="Spontaneous Publicity" />
	<atom:link rel='hub' href='http://lfoust.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Finding Out which Groups a User is a Member Of When Using Windows Authentication in Asp.Net</title>
		<link>http://lfoust.wordpress.com/2008/03/13/finding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet/</link>
		<comments>http://lfoust.wordpress.com/2008/03/13/finding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet/#comments</comments>
		<pubDate>Thu, 13 Mar 2008 18:44:07 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/03/13/finding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet/</guid>
		<description><![CDATA[When using Windows authentication with Asp.net, I often need to know which active directory groups a user is a member of. Now I know that you can do something like: if (User.IsInRole("Admin")) { //Give Access to Secrets } The problem with this is you need to know the name of the group ahead of time. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=128&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>When using Windows authentication with Asp.net, I often need to know which active directory groups a user is a member of. Now I know that you can do something like:</p>
<pre><span style="color:blue;">if </span>(User.IsInRole(<span style="color:#a31515;">"Admin"</span>))
{
    <span style="color:green;">//Give Access to Secrets
</span>}</pre>
<p>The problem with this is you need to know the name of the group ahead of time. And what if you are on a network where the full name of a group is not always clear. The actual group name may be &#8220;MyDomain\Admin&#8221;. So I wrote up a quick way to just get a list of all the groups a user is a member of. It isn&#8217;t super straight forward (as far as which types you need to cast to) so I thought I would list it out here:
<pre><span style="color:blue;">public static </span><span style="color:#2b91af;">List</span>&lt;<span style="color:blue;">string</span>&gt; GetGroups(<span style="color:#2b91af;">RolePrincipal </span>user)
{
    <span style="color:#2b91af;">List</span>&lt;<span style="color:blue;">string</span>&gt; groups = <span style="color:blue;">new </span><span style="color:#2b91af;">List</span>&lt;<span style="color:blue;">string</span>&gt;();

    <span style="color:#2b91af;">WindowsIdentity </span>identity = p.Identity <span style="color:blue;">as </span><span style="color:#2b91af;">WindowsIdentity</span>;
    <span style="color:blue;">foreach </span>(<span style="color:#2b91af;">IdentityReference </span>group <span style="color:blue;">in </span>identity.Groups)
    {
        <span style="color:#2b91af;">NTAccount </span>account = (<span style="color:#2b91af;">NTAccount</span>)group.Translate(<span style="color:blue;">typeof</span>(<span style="color:#2b91af;">NTAccount</span>));

        groups.Add(account.Value);
    }

    <span style="color:blue;">return </span>groups;
}</pre>
<p>the user of it on a web page would be something like:
<pre><span style="color:#2b91af;">List</span>&lt;<span style="color:blue;">string</span>&gt; groups = GetGroups(User <span style="color:blue;">as </span><span style="color:#2b91af;">RolePrincipal</span>);</pre>
<p>Keep in mind that this is assuming you are using Windows Authentication. So the weird part of the code above is:<a href="http://11011.net/software/vspaste"></a></p>
<p><span style="color:#2b91af;">NTAccount </span>account = (<span style="color:#2b91af;">NTAccount</span>)group.Translate(<span style="color:blue;">typeof</span>(<span style="color:#2b91af;">NTAccount</span>)); </p>
<p>if you do not get this step, you will just get a bunch of Active Directory IDs that won&#8217;t do you much good.</p>
<p>Also, sorry about the long title. I just can&#8217;t think of a clever title today. Maybe I should add something like &#8220;Ultimate Edition for Developers&#8221; on the end to make it extra clear.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f03%2f13%2ffinding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet%2f"><img src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f03%2f13%2ffinding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet%2f" border="0" alt="kick it on DotNetKicks.com" /></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/128/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/128/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/128/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/128/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/128/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/128/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/128/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/128/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/128/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/128/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=128&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/03/13/finding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f03%2f13%2ffinding-out-which-groups-a-user-is-a-member-of-when-using-windows-authentication-in-aspnet%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>What I Miss</title>
		<link>http://lfoust.wordpress.com/2008/03/11/what-i-miss/</link>
		<comments>http://lfoust.wordpress.com/2008/03/11/what-i-miss/#comments</comments>
		<pubDate>Tue, 11 Mar 2008 17:43:06 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/03/11/what-i-miss/</guid>
		<description><![CDATA[So I have been living up here in Washington for about 5 months now and I am really missing some of the food I am used to in San Diego. In no particular order they are: In N Out Lolita&#8217;s Taco Shop Phil&#8217;s Barbeque Hopefully it is just a matter of having to learn about [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=127&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>So I have been living up here in Washington for about 5 months now and I am really missing some of the food I am used to in San Diego. In no particular order they are:</p>
<ul>
<li><a href="http://lfoust.files.wordpress.com/2008/03/nnout.png" target="_blank"><img style="border-right:0;border-top:0;border-left:0;border-bottom:0;" height="138" alt="nnout" src="http://lfoust.files.wordpress.com/2008/03/nnout-thumb.png?w=240&#038;h=138" width="240" align="right" border="0"> In N Out</a></li>
<li><a href="http://sandiego.citysearch.com/profile/386721/bonita_ca/lolitas_taco_shop.html" target="_blank">Lolita&#8217;s Taco Shop</a></li>
<li><a href="http://www.philsbbq.net/" target="_blank">Phil&#8217;s Barbeque</a></li>
</ul>
<p>Hopefully it is just a matter of having to learn about the local spots up here for good food. I am not all that hopeful that I will find mexican food up here like they have in San Diego.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/127/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/127/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/127/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/127/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/127/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/127/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/127/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/127/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/127/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/127/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=127&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/03/11/what-i-miss/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/03/nnout-thumb.png" medium="image">
			<media:title type="html">nnout</media:title>
		</media:content>
	</item>
		<item>
		<title>Using BlogEngine.net as a General Purpose Content Management System &#8211; Part I</title>
		<link>http://lfoust.wordpress.com/2008/02/28/using-blogenginenet-as-a-general-purpose-content-management-system-part-i/</link>
		<comments>http://lfoust.wordpress.com/2008/02/28/using-blogenginenet-as-a-general-purpose-content-management-system-part-i/#comments</comments>
		<pubDate>Thu, 28 Feb 2008 07:32:46 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/?p=124</guid>
		<description><![CDATA[So I keep running into the same problem &#8211; I am building a small website for somebody (in this case, my Mom) and I need to provide them with a way to update the content of their site so I don&#8217;t have to. Basically, I need a lightweight and flexible content management system that is [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=124&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>So I keep running into the same problem &#8211; I am building a small website for somebody (in this case, <a title="My Mom's Website" href="http://www.govizsla.com" target="_blank">my Mom</a>) and I need to provide them with a way to update the content of their site so I don&#8217;t have to. Basically, I need a lightweight and flexible content management system that is easy to use.</p>
<p>In this series of posts, I will show how I converted a small website from just standard .aspx pages into a site where all pages are editable by <a href="http://windowslivewriter.spaces.live.com/" target="_blank">Windows Live Writer</a> and via an online interface. In Part I of this series I will just set some background on how I am approaching the creation of this lightweight CMS.</p>
<h3>If The Shoe Fits&#8230;</h3>
<p><img style="border-width:0;margin:0 0 0 5px;" height="125" alt="cms" src="http://lfoust.files.wordpress.com/2008/02/cms.png?w=125&#038;h=125" width="125" align="right" border="0">When I first thought of a lightweight CMS, I thought of <a href="http://graffiticms.com/" target="_blank">graffiti</a>. It sounds like exactly what I need. So I downloaded the express edition and started evaluating it. It seemed like a nice product and all is not free for commercial use ($399 is the cheapest commercial licence) and I can&#8217;t afford that price tag when building small websites.</p>
<p>Enter <a href="http://www.dotnetblogengine.net/" target="_blank">BlogEngine.net</a>. My favorite blogging platform. There, I said it. I host my blog on <a href="http://www.wordpress.com" target="_blank">wordpress</a> but I like BlogEngine.net better. In fact, I will probably be migrating to BlogEngine.net in the near future. How do I know I like it so much? Well, I use it to run <a href="http://www.bossladyblog.com" target="_blank">my wife&#8217;s blog</a> and I am constantly tinkering around with her site all of the time because I enjoy using BlogEngine.net so much.</p>
<p>I thought that BlogEngine.net has all of the key pieces I needed for my lightweight CMS:</p>
<ol>
<li>A WYSIWYG Editor
<li>A Metaweblog interface
<li>Tons of extensibility</li>
</ol>
<h3>Basic Idea</h3>
<p>I decided to base my CMS implementation on the concept of pages. Most blog engines have two distinct types of content: pages and posts. Posts are the typical type of content that becomes part of your blogs feed whereas pages are usually static content which can be anything outside of a blog post (for example an &#8216;About Me&#8217; page). BlogEngine.net already has everything I need to get the content of page created and persisted in a data store (it supports xml and <a href="http://www.dotnetblogengine.net/wiki/SQLServerBlogProvider.ashx" target="_blank">sql server</a> out of the box). I decided to write a web control which I can place on any webpage and include the contents of a given page from the data store.</p>
<p>I made a control called PageViewer which you can place on the page like this:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">blog</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">PageViewer</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="view"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(255,0,0);">DisplayTitle</span><span style="color:rgb(0,0,255);">="false"
</span>    <span style="color:rgb(255,0,0);">PageId</span><span style="color:rgb(0,0,255);">="167eb7f3-135b-4f90-9756-be25ec10f14c"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p>This control basically just looks up the page using the given id (this functionality is all provided by the existing BlogEngine.Core library) and displays its content. Here is the rendering logic
<pre>BlogEngine.Core.<span style="color:rgb(43,145,175);">Page</span> page = <span style="color:rgb(0,0,255);">null</span>;
<span style="color:rgb(0,0,255);">if</span> (PageId != <span style="color:rgb(43,145,175);">Guid</span>.Empty)
    page = BlogEngine.Core.<span style="color:rgb(43,145,175);">Page</span>.GetPage(PageId);

<span style="color:rgb(0,0,255);">if</span> (page != <span style="color:rgb(0,0,255);">null</span>)
{
    <span style="color:rgb(43,145,175);">ServingEventArgs</span> arg = <span style="color:rgb(0,0,255);">new</span> <span style="color:rgb(43,145,175);">ServingEventArgs</span>(page.Content, <span style="color:rgb(43,145,175);">ServingLocation</span>.SinglePage);
    BlogEngine.Core.<span style="color:rgb(43,145,175);">Page</span>.OnServing(page, arg);

    <span style="color:rgb(0,0,255);">if</span> (arg.Cancel)
        Page.Response.Redirect(<span style="color:rgb(163,21,21);">"error404.aspx"</span>, <span style="color:rgb(0,0,255);">true</span>);

    <span style="color:rgb(0,0,255);">if</span> (DisplayTitle)
    {
        writer.Write(<span style="color:rgb(163,21,21);">"&lt;h1&gt;"</span>);
        writer.Write(page.Title);
        writer.Write(<span style="color:rgb(163,21,21);">"&lt;/h1&gt;"</span>);
    }

    writer.Write(<span style="color:rgb(163,21,21);">"&lt;div&gt;"</span>);
    writer.Write(arg.Body);
    writer.Write(<span style="color:rgb(163,21,21);">"&lt;/div&gt;"</span>);
}</pre>
<p>This code is pretty straight forward &#8211; all it does is get an instance of the page and then display its title in &lt;h1&gt; a tag and its body in &lt;div&gt; tag. This logic is actually straight from the existing page retrieval code that already exists in BlogEngine.net. This web control is pretty much the only new code I had to write. The rest of the project mostly involves moving files around and removing parts of the BlogEngine.net framework that I don&#8217;t need.</p>
<p>Armed with this control, we are ready to start converting the static pages from the old version of the website to be BlogEngine.net pages which can be stored and retrieved using the BlogEngine.Core classes. </p>
<p>In part II of this series, I will cover what changes I made to the website project used for BlogEngine.net blogs to make it function like a straight up website, not a blog. Any feedback is welcome.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f28%2fusing-blogenginenet-as-a-general-purpose-content-management-system-part-i%2f"><img src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f28%2fusing-blogenginenet-as-a-general-purpose-content-management-system-part-i%2f" border="0" alt="kick it on DotNetKicks.com" /></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/124/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/124/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/124/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=124&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/02/28/using-blogenginenet-as-a-general-purpose-content-management-system-part-i/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/02/cms.png" medium="image">
			<media:title type="html">cms</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f28%2fusing-blogenginenet-as-a-general-purpose-content-management-system-part-i%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>YUI: I Officially Can&#8217;t Keep Up</title>
		<link>http://lfoust.wordpress.com/2008/02/20/yui-i-officially-cant-keep-up/</link>
		<comments>http://lfoust.wordpress.com/2008/02/20/yui-i-officially-cant-keep-up/#comments</comments>
		<pubDate>Wed, 20 Feb 2008 19:44:43 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[YUI.Net]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/02/20/yui-i-officially-cant-keep-up/</guid>
		<description><![CDATA[First off, congratulations to Eric Miraglia and the YUI team &#8211; they have just announced the release of YUI 2.5.0: The YUI Team just released version 2.5.0 of the library. We’ve added six new components — Layout Manager, Uploader (multi-file upload engine combining Flash and JavaScript), Resize Utility, ImageCropper, Cookie Utility and a ProfilerViewer Control [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=121&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>First off, congratulations to Eric Miraglia and the <a href="http://developer.yahoo.com/yui/" target="_blank">YUI team</a> &#8211; they have just <a href="http://yuiblog.com/blog/2008/02/20/yui-250-released/" target="_blank">announced the release of YUI 2.5.0</a>:</p>
<blockquote><p>The YUI Team just released <a href="http://developer.yahoo.com/yui/download/">version 2.5.0 of the library</a>. We’ve added six new components — <a href="http://developer.yahoo.com/yui/layout/">Layout Manager</a>, <a href="http://developer.yahoo.com/yui/uploader/">Uploader</a> (multi-file upload engine combining Flash and JavaScript), <a href="http://developer.yahoo.com/yui/resize/">Resize Utility</a>, <a href="http://developer.yahoo.com/yui/imagecropper/">ImageCropper</a>, <a href="http://developer.yahoo.com/yui/cookie/">Cookie Utility</a> and a <a href="http://developer.yahoo.com/yui/profilerviewer/">ProfilerViewer Control</a> that works in tandem with the YUI <a href="http://developer.yahoo.com/yui/profiler/">Profiler</a>. This release also contains major improvements to the <a href="http://developer.yahoo.com/yui/datatable/">DataTable Control</a> and new<a href="http://developer.yahoo.com/yui/slider/#dual"> Dual-Thumb Slider functionality</a> in the Slider Control.</p>
</blockquote>
<p>Six new components?!? Man, I just can&#8217;t keep up with learning all this new stuff let alone keep <a href="http://www.codeplex.com/YuiDotNet" target="_blank">YUI.Net</a> up to date.</p>
<h3>Roadmap Gone Off Track</h3>
<p><img style="border-right:0;border-top:0;border-left:0;border-bottom:0;" height="91" alt="waitup" src="http://lfoust.files.wordpress.com/2008/02/waitup.png?w=158&#038;h=91" width="158" align="right" border="0"> I was working on a roadmap for YUI.Net but now I have some serious consideration to do about what next steps to take. Although there has been plenty of interest in the YUI.Net project, nobody has really come forward to help out. I am not complaining. I really enjoy working on YUI.Net. I just don&#8217;t have the time to dedicate to it right now. I am going to continue to follow the development of the YUI, but I don&#8217;t think I will continue development on the YUI.Net library for the foreseeable future.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/121/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/121/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/121/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/121/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/121/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/121/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/121/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/121/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/121/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/121/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=121&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/02/20/yui-i-officially-cant-keep-up/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/02/waitup.png" medium="image">
			<media:title type="html">waitup</media:title>
		</media:content>
	</item>
		<item>
		<title>Google Charts for Asp.Net now on Codeplex</title>
		<link>http://lfoust.wordpress.com/2008/02/10/google-charts-for-aspnet-now-on-codeplex/</link>
		<comments>http://lfoust.wordpress.com/2008/02/10/google-charts-for-aspnet-now-on-codeplex/#comments</comments>
		<pubDate>Sun, 10 Feb 2008 20:59:00 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Google Charts]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2008/02/10/google-charts-for-aspnet-now-on-codeplex/</guid>
		<description><![CDATA[I have received very positive feedback on my Asp.Net control for Google charts so I decided to place it up on Codeplex to allow people to participate and add code to the project. I am currently working on a project roadmap so please let me know if you are interested in participating. One feature I [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=119&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><img style="border-width:0;margin:0 0 0 20px;" height="84" alt="image" src="http://lfoust.files.wordpress.com/2008/02/image1.png?w=235&#038;h=84" width="235" align="right" border="0"> I have received very positive feedback on my <a href="http://blog.spontaneouspublicity.com/2007/12/09/aspnet-control-for-google-charts/" target="_blank">Asp.Net control for Google charts</a> so I decided to place it up on <a href="http://www.codeplex.com/GoogleCharts" target="_blank">Codeplex</a> to allow people to participate and add code to the project.</p>
<p>I am currently working on a project roadmap so please let me know if you are interested in participating. One feature I have already begun work on is giving the control support for data binding.</p>
<p>Here is some example data binding code I have got working:</p>
<pre><span style="color:rgb(0,0,255);">protected</span> <span style="color:rgb(0,0,255);">void</span> Page_Load(<span style="color:rgb(0,0,255);">object</span> sender, <span style="color:rgb(43,145,175);">EventArgs</span> e)
{
    chart.DataSource = GetDataSource();
    chart.DataBind();
}

<span style="color:rgb(0,0,255);">private</span> <span style="color:rgb(43,145,175);">DataTable</span> GetDataSource()
{
    <span style="color:rgb(43,145,175);">DataTable</span> table = <span style="color:rgb(0,0,255);">new</span> <span style="color:rgb(43,145,175);">DataTable</span>();

    table.Columns.Add(<span style="color:rgb(163,21,21);">"Type"</span>, <span style="color:rgb(0,0,255);">typeof</span>(<span style="color:rgb(0,0,255);">string</span>));
    table.Columns.Add(<span style="color:rgb(163,21,21);">"Jan"</span>, <span style="color:rgb(0,0,255);">typeof</span>(<span style="color:rgb(0,0,255);">float</span>));
    table.Columns.Add(<span style="color:rgb(163,21,21);">"Feb"</span>, <span style="color:rgb(0,0,255);">typeof</span>(<span style="color:rgb(0,0,255);">float</span>));
    table.Columns.Add(<span style="color:rgb(163,21,21);">"Mar"</span>, <span style="color:rgb(0,0,255);">typeof</span>(<span style="color:rgb(0,0,255);">float</span>));

    table.Rows.Add(<span style="color:rgb(163,21,21);">"Men"</span>, 68, 78, 88);
    table.Rows.Add(<span style="color:rgb(163,21,21);">"Women"</span>, 68, 58, 78);
    table.Rows.Add(<span style="color:rgb(163,21,21);">"Both"</span>, 88, 48, 98);
    <span style="color:rgb(0,0,255);">return</span> table;
}</pre>
<p>I am just binding to a simple DataTable which has one column containing the labels for the chart and multiple other columns which contain the data for the chart. The code above produces the following chart:</p>
<p><img style="border-width:0;" height="100" alt="image" src="http://lfoust.files.wordpress.com/2008/02/image2.png?w=400&#038;h=100" width="400" border="0"> </p>
<p>I look forward to seeing this project improve.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f10%2fgoogle-charts-for-aspnet-now-on-codeplex%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f10%2fgoogle-charts-for-aspnet-now-on-codeplex%2f" border="0"></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/119/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/119/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/119/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/119/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/119/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/119/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/119/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/119/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/119/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/119/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=119&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/02/10/google-charts-for-aspnet-now-on-codeplex/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/02/image1.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/02/image2.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f10%2fgoogle-charts-for-aspnet-now-on-codeplex%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>C# Language Improvements: Know What You Are Getting Into</title>
		<link>http://lfoust.wordpress.com/2008/02/06/c-language-improvements-know-what-you-are-getting-into/</link>
		<comments>http://lfoust.wordpress.com/2008/02/06/c-language-improvements-know-what-you-are-getting-into/#comments</comments>
		<pubDate>Wed, 06 Feb 2008 16:21:30 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/?p=114</guid>
		<description><![CDATA[The C# language has changed a lot since its initial release in 2000. C# 2.0 brought us: Generics Iterators Anonymous Methods Partial Classes Nullable Types Static Classes Property and Indexer Accesability Changes C# 3.0 brought us: LINQ Automatic Properties Object and Collection Initializers Lambda Expressions Extension Methods Anonymous Types Local Variable Type Inference And that [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=114&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The C# language has changed a lot since its <a href="http://www.microsoft.com/presspass/press/2000/jun00/CsharpPR.mspx" target="_blank">initial release</a> in 2000. C# 2.0 brought us:</p>
<ul>
<li><a href="http://msdn2.microsoft.com/en-us/library/512aeb7t.aspx" target="_blank">Generics</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/dscyy5s0.aspx" target="_blank">Iterators</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/98dc08ac.aspx" target="_blank">Anonymous Methods</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/wa80x488.aspx" target="_blank">Partial Classes</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/1t3y8s4s(VS.80).aspx" target="_blank">Nullable Types</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/79b3xss3.aspx" target="_blank">Static Classes</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/75e8y5dd.aspx" target="_blank">Property and Indexer Accesability Changes</a> </li>
</ul>
<p><a href="http://lfoust.files.wordpress.com/2008/02/image.png"><img style="border-width:0;" height="202" alt="image" src="http://lfoust.files.wordpress.com/2008/02/image-thumb.png?w=169&#038;h=202" width="169" align="right" border="0"></a>C# 3.0 brought us:</p>
<ul>
<li><a href="http://msdn2.microsoft.com/en-us/vcsharp/aa904594.aspx" target="_blank">LINQ</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/bb384054.aspx" target="_blank">Automatic Properties</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/bb384062.aspx" target="_blank">Object and Collection Initializers</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/bb531253.aspx" target="_blank">Lambda Expressions</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/bb383977.aspx" target="_blank">Extension Methods</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/bb397696.aspx" target="_blank">Anonymous Types</a>
<li><a href="http://msdn2.microsoft.com/en-us/library/bb384061.aspx" target="_blank">Local Variable Type Inference</a> </li>
</ul>
<p>And that is just the new language features in the last 3 years! This does not include all of the new classes added to the BCL over the same time period.</p>
<h3>Know the Cost</h3>
<p>I am as excited about these new changes as the next guy. I have used various combinations of these improvements in my projects with great success. But is there a cost to new features?</p>
<p>Recently I read a couple of articles that reminded me that you not only have to understand how a feature is used, you also have to understand the cost of using it. Sometimes that cost is performance, other times it could be something like readability or portability. I&#8217;ll take one example from the 2.0 framework and then one from the 3.5 framework to show that you need to understand the implications of using new features.</p>
<h3>Yield Return</h3>
<p>First, there is Fritz Onion&#8217;s <a href="http://www.pluralsight.com/blogs/fritz/archive/2008/02/06/50166.aspx" target="_blank">recent post</a> on the amount of code generated by the yield return syntax introduced in C# 2.0:</p>
<blockquote><p>The array allocation function generated a total of 20 lines of IL, but the yield return function, if you included all of the IL instructions for the IEnumerable class generation as well was over 100! That&#8217;s a 5x penalty in code generation to save 18 characters of typing</p>
</blockquote>
<p>So is the 5x penalty ever worth it? Yes, of course it is. There are things you can do with yield that you couldn&#8217;t do previously. In most cases, the use of yield improves readability dramatically. It also makes the task of creating a custom enumerator <strong>much</strong> easier.</p>
<p>In his article <a href="http://flimflan.com/blog/ThePowerOfYieldReturn.aspx" target="_blank">The power of yield return</a>, Joshua Flanagan points to an example where using the yield return improved performance dramatically:</p>
<blockquote><p><strong>With the improved implementation that took advantage of the yield keyword, the program was able to finish its job in less than half the time!</strong> It also used much less memory, as it never had to store all 9 strings in a collection. Now imagine the potential impact if GetCombinations returned a collection with thousands of entries!</p>
</blockquote>
<p>The point here is that you have to know the costs and how they fit in with the requirements of the project you are working on. If you are building something that must support thousands of concurrent users and must be very performant, you will most likely choose to use the yield return despite the extra code generated by the compiler.</p>
<h3>LINQ is Dead, Long Live LINQ</h3>
<p>Most of the time when I show somebody the new language enhancements in C# 3.0, the thing that interests them the most (and rightly so) is <a href="http://msdn2.microsoft.com/en-us/vcsharp/aa904594.aspx" target="_blank">LINQ</a>. It is just so different to see query syntax built right into the language. The next question they usually ask is how the performance of something written using LINQ would compare the same procedure written using just C# 2.0 control structures.</p>
<p>Steve Hebert recently wrote a <a href="http://codebetter.com/blogs/steve.hebert/archive/2008/02/06/linq-to-objects-relating-data-structure-organization-to-where-clause-optimization.aspx" target="_blank">post about LINQ performance</a> where he concludes:</p>
<blockquote><p><strong>Despite my best efforts I just couldn’t make my hand-written code perform as poorly as Linq</strong></p>
</blockquote>
<p>What? Seriously? Wow. Then I guess we should stay away from LINQ then right? Well, if you look closer at his post, you will notice that he has optimized his non LINQ version of the code a little bit for the underlying data structure where LINQ has to be able to operate regardless of the underlying data structure. I am not so much interested in the particulars so much as I am the idea that you should understand these things before you start replacing all of your for loops with LINQ queries.</p>
<h3>Shifting Sands</h3>
<p>One more recent post that fits in here. Rob Conery wrote about his <a href="http://blog.wekeroad.com/2008/02/05/crazy-talk-inline-scripting-revisited-or-2003-bites-back/" target="_blank">recent experience</a> where his 5 year old code has come back to haunt him:</p>
<blockquote><p>I spose the moral of the story is to <strong>always view the concept of maintenance with an eye towards shifting toolsets and platforms</strong>. In 4 years you will need to support the ASP.NET 2.0 site you’re on now, using Visual Studio 2012 and it’s Silverlight-generated Scaffolds <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> . </p>
</blockquote>
<p>This is a great reminder of how tough it can be to deal with changes in technology. I mean, come on, he couldn&#8217;t find a machine to compile his 5 year old code?!? I know we can all relate. With the technology learning curve growing at a semi exponential way, just imagine where that same code will be in another 5 years.</p>
<h3>Back to Machine Code</h3>
<p><img height="217" src="http://www.polyweb.com/blog/images/zx81/ZX81MachineCode.jpg" width="148" align="left">Obviously I am not advocating that we just give up on new features because they might not be as fast or resource efficient as our hand coded machine code. In fact, I think we need to embrace abstractions wherever possible. They make our jobs as software developers much easier. Just be smart about it. Have some idea what is going on behind the covers. It is important to realize that yield return eventually becomes a bunch of compiler generated code and that LINQ queries are general case and they may not always be as great as manually doing the coding yourself.</p>
<p>Maybe the documentation on these new language features could do a better job at explaining what sorts of considerations we need to take into account when using them in our applications.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f06%2fc-language-improvements-know-what-you-are-getting-into%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f06%2fc-language-improvements-know-what-you-are-getting-into%2f" border="0"></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/114/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/114/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/114/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/114/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/114/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/114/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/114/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/114/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/114/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/114/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=114&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/02/06/c-language-improvements-know-what-you-are-getting-into/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/02/image-thumb.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://www.polyweb.com/blog/images/zx81/ZX81MachineCode.jpg" medium="image" />

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f02%2f06%2fc-language-improvements-know-what-you-are-getting-into%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>Microsoft + Yahoo! and My Affair With YUI</title>
		<link>http://lfoust.wordpress.com/2008/02/01/microsoft-yahoo-and-my-affair-with-yui/</link>
		<comments>http://lfoust.wordpress.com/2008/02/01/microsoft-yahoo-and-my-affair-with-yui/#comments</comments>
		<pubDate>Fri, 01 Feb 2008 17:05:21 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[YUI.Net]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/02/01/microsoft-yahoo-and-my-affair-with-yui/</guid>
		<description><![CDATA[If you read my blog regularly, there are two things you may or may not know about me: I work at Microsoft I love the Yahoo User Interface Library So today&#8217;s big news that Microsoft has offered to buy Yahoo! for 44.6 billion dollars speaks to both of these facts about me. This is obviously [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=113&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>If you read my blog regularly, there are two things you may or may not know about me:</p>
<ul>
<li>I <a href="http://blog.spontaneouspublicity.com/2007/10/11/life-changes-so-fast/" target="_blank">work</a> at Microsoft</li>
<li>I love the <a href="http://developer.yahoo.com/yui/" target="_blank">Yahoo User Interface Library</a></li>
</ul>
<p>So today&#8217;s big news that <a href="http://www.msnbc.msn.com/id/22947626" target="_blank">Microsoft has offered to buy Yahoo! for 44.6 billion dollars</a> speaks to both of these facts about me. This is obviously big news for both Yahoo! and Microsoft and many people have their <a href="http://blogs.zdnet.com/microsoft/?p=1144" target="_blank">different takes</a> on <a href="http://slashdot.org/article.pl?sid=08/02/01/1353211" target="_blank">whether or not it is a good idea or not</a>. I just want to say that I am feeling like my secret love affair with YUI is somehow more justified after hearing this news.</p>
<p>Now if I build sites using the <a title="Reset is my friend" href="http://developer.yahoo.com/yui/reset/" target="_blank">YUI CSS library</a>, or work on <a href="http://www.codeplex.com/YuiDotNet" target="_blank">YUI.Net</a>, I can be comforted by the fact that I wasn&#8217;t the first one to think of Microsoft + Yahoo! being a happy combination.</p>
<p>By the way, I realize that I haven&#8217;t added any new code to the YUI.Net controls in a long time. I am working on a roadmap of how to move forward and would love any feedback from people who have used the controls. </p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/113/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/113/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/113/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=113&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/02/01/microsoft-yahoo-and-my-affair-with-yui/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>C# Enum Craziness: Sometimes What You Expect Isn&#8217;t The Case</title>
		<link>http://lfoust.wordpress.com/2008/01/28/c-enum-craziness/</link>
		<comments>http://lfoust.wordpress.com/2008/01/28/c-enum-craziness/#comments</comments>
		<pubDate>Mon, 28 Jan 2008 17:59:37 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/01/28/c-enum-craziness/</guid>
		<description><![CDATA[I learned something new today about enums that I find really weird. Lets start with the following test enum: public enum Action { Run = 2, Walk = 4, Crawl = 8 } and then some code to do something with that enum: static void Main(string[] args) { Console.WriteLine((Action)2); Console.WriteLine((Action)4); Console.WriteLine((Action)8); Console.WriteLine((Action)10); } What do [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=112&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I learned something new today about enums that I find really weird. Lets start with the following test enum:</p>
<pre><span style="color:blue;">public enum </span><span style="color:#2b91af;">Action
</span>{
    Run = 2,
    Walk = 4,
    Crawl = 8
}</pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>and then some code to do something with that enum:</p>
<pre><span style="color:blue;">static void </span>Main(<span style="color:blue;">string</span>[] args)
{
    <span style="color:#2b91af;">Console</span>.WriteLine((<span style="color:#2b91af;">Action</span>)2);
    <span style="color:#2b91af;">Console</span>.WriteLine((<span style="color:#2b91af;">Action</span>)4);
    <span style="color:#2b91af;">Console</span>.WriteLine((<span style="color:#2b91af;">Action</span>)8);
    <span style="color:#2b91af;">Console</span>.WriteLine((<span style="color:#2b91af;">Action</span>)10);
}</pre>
<p><a href="http://11011.net/software/vspaste"></a>What do you think will happen here? Will it even compile?</p>
<p>When I saw this code snippet I said to myself, &#8220;the first three lines look ok but the last line won&#8217;t work because 10 isn&#8217;t a valid value for this enum. Well, I was wrong. This program actually outputs:</p>
<pre>Run
Walk
Crawl
10</pre>
<p><a href="http://11011.net/software/vspaste"></a>Huh?!? How could this be? 10 isn&#8217;t a valid value according to my enum definition!</p>
<h2>This Should Never Happen&#8230;Right?</h2>
<p>Ok, lets try something different. How about a method?</p>
<pre><span style="color:blue;">public static void </span>Execute(<span style="color:#2b91af;">Action </span>action)
{
    <span style="color:blue;">switch </span>(action)
    {
        <span style="color:blue;">case </span><span style="color:#2b91af;">Action</span>.Run:
            <span style="color:#2b91af;">Console</span>.WriteLine(<span style="color:#a31515;">"Running"</span>);
            <span style="color:blue;">break</span>;
        <span style="color:blue;">case </span><span style="color:#2b91af;">Action</span>.Walk:
            <span style="color:#2b91af;">Console</span>.WriteLine(<span style="color:#a31515;">"Walking"</span>);
            <span style="color:blue;">break</span>;
        <span style="color:blue;">case </span><span style="color:#2b91af;">Action</span>.Crawl:
            <span style="color:#2b91af;">Console</span>.WriteLine(<span style="color:#a31515;">"Crawling"</span>);
            <span style="color:blue;">break</span>;
        <span style="color:blue;">default</span>:
            <span style="color:#2b91af;">Console</span>.WriteLine(<span style="color:#a31515;">"This will never happen! {0}"</span>, action);
            <span style="color:blue;">break</span>;
    }
}</pre>
<p><a href="http://11011.net/software/vspaste"></a>Surely you can&#8217;t pass anything into this method other than one of the 3 values defined in my enum. So lets run some code:
<pre><span style="color:blue;">static void </span>Main(<span style="color:blue;">string</span>[] args)
{
    Execute(<span style="color:#2b91af;">Action</span>.Run);
    Execute(<span style="color:#2b91af;">Action</span>.Walk);
    Execute((<span style="color:#2b91af;">Action</span>)55);
}</pre>
<p>What do you think this does? Well, it outputs:
<pre>Running
Walking
This will never happen! 55</pre>
<p><a href="http://11011.net/software/vspaste"></a>Just about this time you must be thinking: &#8220;This has to be a bug!&#8221;. Well, it is not. It is by design. here is the excerpt from the C# design spec:</p>
<blockquote>
<p><b><a href="http://msdn2.microsoft.com/en-us/library/aa664601(VS.71).aspx">14.5 Enum values and operations</a></b> </p>
<p><a name="vclrfcsharpspec_14_5"></a>Each enum type defines a distinct type; an explicit enumeration conversion <a href="http://msdn2.microsoft.com/en-us/library/aa691290(VS.71).aspx">(Section 6.2.2)</a> is required to convert between an enum type and an integral type, or between two enum types. The set of values that an enum type can take on is not limited by its enum members. In particular, any value of the underlying type of an enum can be cast to the enum type, and is a distinct valid value of that enum type.</p>
</blockquote>
<p><font color="#777777">Wow, that is not at all what I expected when it comes to limiting the possible values of enums. So what are enums good for then? Are they just for code readability? Between this little revelation and <a href="http://blog.spontaneouspublicity.com/2008/01/17/associating-strings-with-enums-in-c/" target="_blank">my previous hack to associate string values to enums</a>, I am loosing faith in enums.</font> </p>
<h2>Can You Handle it?</h2>
<p><font color="#777777">So what is the best way to check for this in your methods? Should you throw an exception if you receive an enum value you were not expecting? Should you just ignore it? Well, lets see what the .Net base class libraries do.</font> </p>
<p><font color="#777777">First, lets start with the System.IO.File class. What happens if I run the following code?</font>
<pre><span style="color:#2b91af;">File</span>.Open(<span style="color:#a31515;">@"C:\temp\test.txt"</span>, (<span style="color:#2b91af;">FileMode</span>)500);</pre>
<p>Well, it throws a System.ArgumentOutOfRangeException with the message &#8220;Enum value was out of legal range.&#8221;. Ok, makes sense &#8211; I did pass in something out of range.</p>
<p>Lets try reflection. What does the following code snippet output?</p>
<pre><span style="color:#2b91af;">PropertyInfo</span>[] info = <span style="color:blue;">typeof</span>(<span style="color:#2b91af;">StringBuilder</span>).GetProperties((<span style="color:#2b91af;">BindingFlags</span>)303);
<span style="color:#2b91af;">Console</span>.WriteLine(info.Length);</pre>
<p>Well, it just outputs &#8217;0&#8242; which means in this case it is just being ignored and an empty array is returned.</p>
<p>What about System.String? Lets try this code snippet:</p>
<pre><span style="color:#a31515;">"TestString"</span>.Equals(<span style="color:#a31515;">"TESTSTRING"</span>, (<span style="color:#2b91af;">StringComparison</span>)245);</pre>
<p>Well, it turns out this throws an exception but instead of being a System.ArgumentOutOfRangeException like System.IO did, it throws a System.ArgumentException with the message &#8220;The string comparison type passed in is currently not supported.&#8221; Ok, so this is kind of the same but still a little inconsistent if you ask me.</p>
<h2>Is Anything Safe These Days?</h2>
<p>So what is a developer to do? Obviously you need to be aware of this when you are receiving enum types from publicly facing code. It seems there is no clear guidance on this that I can find. The C# design spec explains the behavior but doesn&#8217;t really give any guidance on why or how this should be handled. So the only other place to turn for guidance is one of my favorite .Net books <a title="Framework Design Guidelines" href="http://www.amazon.com/gp/product/0321246756?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0321246756" target="_blank">Framework Design Guidelines</a> by <a href="http://blogs.msdn.com/brada/" target="_blank">Brad Abrams</a> and <a href="http://blogs.msdn.com/kcwalina/" target="_blank">Krzysztof Cwalina</a>. On their section on enums, I can&#8217;t find any guidance on how to handle out of range enum values. I do, however, find guidance that we should be using enums:</p>
<blockquote>
<p><strong>DO</strong> use an enum to strongly type parameters, properties, and return values that represent sets of values</p>
</blockquote>
<p>They also suggest that enums should be favored over static constants:</p>
<blockquote>
<p><strong>DO</strong> favor using an enum over static constants</p>
</blockquote>
<p>And <a href="http://www.wintellect.com/cs/blogs/jeffreyr/default.aspx" target="_blank">Jeffrey Richter</a> (and while I am pointing out my favorite .Net books, I have to add Mr. Richter&#8217;s book <a href="http://www.amazon.com/gp/product/0735621632?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0735621632" target="_blank">CLR via C#</a> which contains priceless information on the CLR that you can&#8217;t find anywhere else) adds the following commentary:</p>
<blockquote>
<p>An enum is a structure with a set of static constants. The reason to follow this guideline is because you will get some additional compiler and reflection support if you define an enum versus manually defining a structure with static constants.</p>
</blockquote>
<p>So I guess we do continue to use enums and just know that we can&#8217;t always trust their values to be valid. Do you think the C# design spec should be amended to include a recommended behavior for out of range enum values? Perhaps Brad and Krzysztof can include something in their <a href="http://blogs.msdn.com/kcwalina/archive/2008/01/03/FrameworkDesignGuidelines2ndEdition.aspx" target="_blank">second edition of Framework Design Guidelines</a>.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f28%2fc-enum-craziness%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f28%2fc-enum-craziness%2f" border="0"></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/112/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/112/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/112/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/112/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/112/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/112/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/112/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/112/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/112/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/112/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=112&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/01/28/c-enum-craziness/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f28%2fc-enum-craziness%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>Associating Strings with enums in C#</title>
		<link>http://lfoust.wordpress.com/2008/01/17/associating-strings-with-enums-in-c/</link>
		<comments>http://lfoust.wordpress.com/2008/01/17/associating-strings-with-enums-in-c/#comments</comments>
		<pubDate>Thu, 17 Jan 2008 21:50:45 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/01/17/associating-strings-with-enums-in-c/</guid>
		<description><![CDATA[I have seen other great articles out lining the benefits of some pretty clever and useful helper classes for enums. Many of these methods almost exactly mirror methods I had written in my own EnumHelper class. (Isn&#8217;t it crazy when you imagine how much code duplication there must be like this out there!) One thing [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=111&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have seen <a href="http://devlicious.com/blogs/christopher_bennage/archive/2007/09/13/my-new-little-friend-enum-lt-t-gt.aspx" target="_blank">other</a> <a href="http://rodenbaugh.net/archive/2006/11/01/Enum-Helper-Class-Using-Generics.aspx" target="_blank">great</a> <a href="http://kirillosenkov.blogspot.com/2007/09/making-c-enums-more-usable-parse-method.html" target="_blank">articles</a> out lining the benefits of some pretty clever and useful helper classes for enums. Many of these methods almost exactly mirror methods I had written in my own EnumHelper class. (Isn&#8217;t it crazy when you imagine how much code duplication there must be like this out there!)</p>
<p>One thing that I don&#8217;t see emphasized much is trying to associated string values with enums. For example, what if you want to have a Drop Down list that you can choose from a list of values (which are backed by an enum)? Lets start with a test enum:</p>
<pre><span style="color:blue;">public enum </span>States
{
    California,
    NewMexico,
    NewYork,
    SouthCarolina,
    Tennessee,
    Washington
}</pre>
<p>So if you made a drop down list out of this enum, using the ToString() method, you would get a drop down that looks like this:</p>
<p><img style="border-width:0;" height="141" alt="image" src="http://lfoust.files.wordpress.com/2008/01/image2.png?w=117&#038;h=141" width="117" border="0"> </p>
<p>While most people will understand this, it should really be displayed like this:</p>
<p><img style="border-width:0;" height="135" alt="image" src="http://lfoust.files.wordpress.com/2008/01/image3.png?w=118&#038;h=135" width="118" border="0"> </p>
<p>&#8220;But enums can&#8217;t have spaces in C#!&#8221; you say. Well, I like to use the System.ComponentModel.DescriptionAttribute to add a more friendly description to the enum values. The example enum can be rewritten like this:</p>
<pre><span style="color:blue;">public enum </span><span style="color:#2b91af;">States
</span>{
    California,
    [<span style="color:#2b91af;">Description</span>(<span style="color:#a31515;">"New Mexico"</span>)]
    NewMexico,
    [<span style="color:#2b91af;">Description</span>(<span style="color:#a31515;">"New York"</span>)]
    NewYork,
    [<span style="color:#2b91af;">Description</span>(<span style="color:#a31515;">"South Carolina"</span>)]
    SouthCarolina,
    Tennessee,
    Washington
}</pre>
<p>Notice that I do not put descriptions on items where the ToString() version of that item displays just fine.</p>
<h2>How Do We Get To the Description?</h2>
<p>Good question! Well, using reflection of course! Here is what the code looks like:</p>
<pre><span style="color:blue;">public static string </span>GetEnumDescription(<span style="color:#2b91af;">Enum </span>value)
{
    <span style="color:#2b91af;">FieldInfo </span>fi = value.GetType().GetField(value.ToString());

    <span style="color:#2b91af;">DescriptionAttribute</span>[] attributes =
        (<span style="color:#2b91af;">DescriptionAttribute</span>[])fi.GetCustomAttributes(
        <span style="color:blue;">typeof</span>(<span style="color:#2b91af;">DescriptionAttribute</span>),
        <span style="color:blue;">false</span>);

    <span style="color:blue;">if </span>(attributes != <span style="color:blue;">null </span>&amp;&amp;
        attributes.Length &gt; 0)
        <span style="color:blue;">return </span>attributes[0].Description;
    <span style="color:blue;">else
        return </span>value.ToString();
}</pre>
<p><a href="http://11011.net/software/vspaste"></a>This method first looks for the presence of a DescriptionAttribute and if it doesn&#8217;t find one, it just returns the ToString() of the value passed in. So </p>
<pre>GetEnumDescription(<span style="color:#2b91af;">States</span>.NewMexico);</pre>
<p>returns the string &#8220;New Mexico&#8221;.</p>
<h2>A Free Bonus: How to Enumerate Enums</h2>
<p>Ok, so now we know how to get the string value of an enum. But as a free bonus, I also have a helper method that allows you to enumerate all the values of a given enum. This will allow you to easily create a drop down list based on an enum. Here is the code for that method:</p>
<pre><span style="color:blue;">public static </span><span style="color:#2b91af;">IEnumerable</span>&lt;T&gt; EnumToList&lt;T&gt;()
{
    <span style="color:#2b91af;">Type </span>enumType = <span style="color:blue;">typeof</span>(T);

    <span style="color:green;">// Can't use generic type constraints on value types,
    // so have to do check like this
    </span><span style="color:blue;">if </span>(enumType.BaseType != <span style="color:blue;">typeof</span>(<span style="color:#2b91af;">Enum</span>))
        <span style="color:blue;">throw new </span><span style="color:#2b91af;">ArgumentException</span>(<span style="color:#a31515;">"T must be of type System.Enum"</span>);

    <span style="color:#2b91af;">Array </span>enumValArray = <span style="color:#2b91af;">Enum</span>.GetValues(enumType);
    <span style="color:#2b91af;">List</span>&lt;T&gt; enumValList = <span style="color:blue;">new </span><span style="color:#2b91af;">List</span>&lt;T&gt;(enumValArray.Length);

    <span style="color:blue;">foreach </span>(<span style="color:blue;">int </span>val <span style="color:blue;">in </span>enumValArray)
    {
        enumValList.Add((T)<span style="color:#2b91af;">Enum</span>.Parse(enumType, val.ToString()));
    }

    <span style="color:blue;">return </span>enumValList;
}</pre>
<p>As you can see, the code for either of these methods isn&#8217;t too complicated. But used in conjunction, they can be really useful. Here is an example of how we would create the drop down list pictured above based on our enum:
<pre><span style="color:#2b91af;">DropDownList </span>stateDropDown = <span style="color:blue;">new </span><span style="color:#2b91af;">DropDownList</span>();
<span style="color:blue;">foreach </span>(<span style="color:#2b91af;">States </span>state <span style="color:blue;">in </span>EnumToList&lt;<span style="color:#2b91af;">States</span>&gt;())
{
    stateDropDown.Items.Add(GetEnumDescription(state));
}</pre>
<p>Pretty simple huh? I hope you find this as useful as I do.</p>
<h2>One More Example</h2>
<p>There is one more scenario that I often find myself needing to associate string values with enums &#8211; when dealing with legacy constant string based system. Lets say you have a library that has the following method:</p>
<pre><span style="color:blue;">public void </span>ExecuteAction(<span style="color:blue;">int </span>value, <span style="color:blue;">string </span>actionType)
{
    <span style="color:blue;">if </span>(actionType == <span style="color:#a31515;">"DELETE"</span>)
        Delete();
    <span style="color:blue;">else if </span>(actionType == <span style="color:#a31515;">"UPDATE"</span>)
        Update();
}</pre>
<p><a href="http://11011.net/software/vspaste"></a>(I tried to make this look as legacy as I could for a contrived example). What happens if somebody passes in &#8220;MyEvilAction&#8221; as a value for actionType? Well, whenever I see hard coded strings, that is a code smell that could possibly point to the use of enums instead. But sometimes you don&#8217;t have control over legacy code and you have to deal with it. So you could make an enum which looks like this:
<pre><span style="color:blue;">public enum </span><span style="color:#2b91af;">ActionType
</span>{
    [<span style="color:#2b91af;">Description</span>(<span style="color:#a31515;">"DELETE"</span>)]
    Delete,
    [<span style="color:#2b91af;">Description</span>(<span style="color:#a31515;">"UPDATE"</span>)]
    Update
}</pre>
<p>(I know, I know, this is a very contrived example) Then you could call the ExecuteAction Method like this:
<pre>ExecuteAction(5, GetEnumDescription(<span style="color:#2b91af;">ActionType</span>.Delete));</pre>
<p>This at least makes the code more readable and may also make it more consistent and secure.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f17%2fassociating-strings-with-enums-in-c%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f17%2fassociating-strings-with-enums-in-c%2f" border="0"></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/111/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/111/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/111/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/111/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/111/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/111/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/111/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/111/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/111/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/111/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=111&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/01/17/associating-strings-with-enums-in-c/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/01/image2.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/01/image3.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f17%2fassociating-strings-with-enums-in-c%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>Useful Code Snippet: Web Property</title>
		<link>http://lfoust.wordpress.com/2008/01/15/useful-code-snippet-web-property/</link>
		<comments>http://lfoust.wordpress.com/2008/01/15/useful-code-snippet-web-property/#comments</comments>
		<pubDate>Tue, 15 Jan 2008 21:41:36 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Productivity Tip]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/01/15/useful-code-snippet-web-property/</guid>
		<description><![CDATA[Write WebControls much? Well, I do and I have a code snippet that I pretty much can&#8217;t live without. It is used for creating ViewState backed properties. Here is the basic pattern I use when creating properties for my web controls: public string Name { get { object o = ViewState["Name"]; return o == null [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=108&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Write WebControls much? Well, I do and I have a code snippet that I pretty much can&#8217;t live without. It is used for creating ViewState backed properties. Here is the basic pattern I use when creating properties for my web controls:</p>
<pre><span style="color:blue;">public string </span>Name
{
    <span style="color:blue;">get
    </span>{
        <span style="color:blue;">object </span>o = ViewState[<span style="color:#a31515;">"Name"</span>];
        <span style="color:blue;">return </span>o == <span style="color:blue;">null </span>? <span style="color:#2b91af;">String</span>.Empty : (<span style="color:blue;">string</span>)o;
    }
    <span style="color:blue;">set </span>{ ViewState[<span style="color:#a31515;">"Name"</span>] = <span style="color:blue;">value</span>; }
}</pre>
<p>Basically, you just want a property (in this case a string named &#8220;Name&#8221;) and you want to store it in ViewState. And when the value is being retrieved, if it is not in ViewState, you want to retrieve some default value. This is a pattern that I repeat over and over in my controls. So I made a code snippet to make it easier.</p>
<p>I use the shortcut &#8216;webprop&#8217;</p>
<p><img style="border-width:0;" height="395" alt="image" src="http://lfoust.files.wordpress.com/2008/01/image.png?w=553&#038;h=395" width="553" border="0"> </p>
<p>and it expands like this:</p>
<p><img style="border-width:0;" height="165" alt="image" src="http://lfoust.files.wordpress.com/2008/01/image1.png?w=441&#038;h=165" width="441" border="0"> </p>
<p>To install, you just need to place the .snippet file (link to download below) in your &#8216;My Snippets&#8217; folder which in windows vista is located at:</p>
<p>C:\Users\&lt;UserName&gt;\Documents\Visual Studio 2005\Code Snippets\Visual C#\My Code Snippets</p>
<p>or if you use Visual Studio 2008:</p>
<p>C:\Users\&lt;UserName&gt;\Documents\Visual Studio 2008\Code Snippets\Visual C#\My Code Snippets</p>
<p>I hope this is helpful. It saves me a bunch of time.</p>
<p><a href="http://www.spontaneouspublicity.com/Downloads/webprop.zip" target="_blank">You can download the .snipped file here</a></p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f15%2fuseful-code-snippet-web-property%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f15%2fuseful-code-snippet-web-property%2f" border="0"></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/108/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/108/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/108/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/108/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/108/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/108/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/108/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/108/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/108/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/108/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=108&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/01/15/useful-code-snippet-web-property/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/01/image.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2008/01/image1.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2008%2f01%2f15%2fuseful-code-snippet-web-property%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>Windows Vista Ultimate Extras &#8211; Sometimes the Truth Hurts</title>
		<link>http://lfoust.wordpress.com/2008/01/09/windows-vista-ultimate-extras-sometimes-the-truth-hurts/</link>
		<comments>http://lfoust.wordpress.com/2008/01/09/windows-vista-ultimate-extras-sometimes-the-truth-hurts/#comments</comments>
		<pubDate>Wed, 09 Jan 2008 17:44:02 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Microsoft]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2008/01/09/windows-vista-ultimate-extras-sometimes-the-truth-hurts/</guid>
		<description><![CDATA[Long Sheng has posted a very humorous and clever post about the lack of Windows Vista Ultimate extras. http://www.istartedsomething.com/20080109/ultimate-extras-inactive-reminder/ I really respect the way that he states the facts and doesn&#8217;t resort to anger. I also love how he has suggestions for possible extras that are very realistic. It is a good practice to always [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=105&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.istartedsomething.com/about/" target="_blank">Long Sheng</a> has posted a very humorous and clever post about the lack of Windows Vista Ultimate extras.</p>
<p><a title="http://www.istartedsomething.com/20080109/ultimate-extras-inactive-reminder/" href="http://www.istartedsomething.com/20080109/ultimate-extras-inactive-reminder/">http://www.istartedsomething.com/20080109/ultimate-extras-inactive-reminder/</a></p>
<p>I really respect the way that he states the facts and doesn&#8217;t resort to anger. I also love how he has suggestions for possible extras that are very realistic. It is a good practice to always suggest a solution whenever you point out a problem.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/105/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/105/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/105/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=105&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2008/01/09/windows-vista-ultimate-extras-sometimes-the-truth-hurts/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>I Was Given the Gift of Smugmug Customer Service</title>
		<link>http://lfoust.wordpress.com/2007/12/31/i-was-given-the-gift-of-smugmug-customer-service/</link>
		<comments>http://lfoust.wordpress.com/2007/12/31/i-was-given-the-gift-of-smugmug-customer-service/#comments</comments>
		<pubDate>Mon, 31 Dec 2007 16:58:20 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/12/31/i-was-given-the-gift-of-smugmug-customer-service/</guid>
		<description><![CDATA[In my previous post, I outlined a little trouble I ran into trying to purchase a friend a Smugmug account as a gift. Well, I am happy to report that the folks at Smugmug responded amazingly and have managed to show how much they care about their customers (as well as potential customers)&#8230;I guess there [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=104&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In my <a href="http://blog.spontaneouspublicity.com/2007/12/29/why-wont-you-let-me-give-the-gift-of-smugmug/">previous post</a>, I outlined a little trouble I ran into trying to purchase a friend a <a href="http://www.smugmug.com/">Smugmug</a> account as a gift. Well, I am happy to report that the folks at Smugmug responded amazingly and have managed to show how much they care about their customers (as well as potential customers)&#8230;I guess there is a reason why they refer to their support personal as &#8220;Support Heroes&#8221;.</p>
<h3>The Man Himself</h3>
<p>If you look at the comments for my <a href="http://blog.spontaneouspublicity.com/2007/12/29/why-wont-you-let-me-give-the-gift-of-smugmug/">previous post</a>, you will notice the first comment is from none other than the founder, CEO and Chief Geek at SmugMug &#8211; Don MacAskill. I love it when leaders of companies care enough about their company that they are willing to step up and participate in the conversation about their company on the Internet. There are a couple of things Don said in his comment that I think explain exactly why I even wrote the first post in the first place:</p>
<blockquote><p>I’m so glad you spoke up about it rather than just shrugging and going somewhere else</p>
</blockquote>
<p>It is usually way easier to just shrug something off. In fact, I was ready to do that and just buy my friend a Flickr account as a gift. But, my wife was persistent about at least seeing the Smugmug thing through and I figured I wasn&#8217;t the only one who had experienced this problem. This is a key point for users of any software: <strong>If you are confused about something or are experiencing any type of difficulty, chances are you are not alone.</strong> It is too easy for users to blame themselves.</p>
<blockquote><p>without feedback like this, we’d never improve, so I’m glad to hear it.</p>
</blockquote>
<p>Smugmug is obviously a company that wants to improve their product any way they can. One reason why I love Don&#8217;s stance on this issue so much, is that I now how hard it is to accept feedback on something you feel so passionate about. Smugmug is a family owned business that Don MacAskill started with his father and he could have just have easily been defensive or taken feedback personally. You&#8217;d be surprised how many CEOs react like that. And don&#8217;t get me started on developers being defensive about their code. Feedback is good. <strong>Wouldn&#8217;t your rather hear what your actual users think rather than just guessing what they must think?</strong></p>
<h3>Above and Beyond</h3>
<p>Well, in the end I was able to give the gift of Smugmug as well as receive a gift because the folks at Smugmug decided to give me and my friend free accounts as a way to show how much they care about any difficulty I have experienced. That is more then I would have ever wanted to come out of this situation. They didn&#8217;t have to do that. But they did. And that is why they have renewed my faith in how much they care about their customers.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/104/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/104/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/104/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/104/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/104/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/104/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/104/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/104/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/104/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/104/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=104&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/12/31/i-was-given-the-gift-of-smugmug-customer-service/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Why Won&#8217;t You Let Me Give the Gift of Smugmug?</title>
		<link>http://lfoust.wordpress.com/2007/12/29/why-wont-you-let-me-give-the-gift-of-smugmug/</link>
		<comments>http://lfoust.wordpress.com/2007/12/29/why-wont-you-let-me-give-the-gift-of-smugmug/#comments</comments>
		<pubDate>Sat, 29 Dec 2007 08:11:08 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/12/29/why-wont-you-let-me-give-the-gift-of-smugmug/</guid>
		<description><![CDATA[Ok, so here is the story. I have some friends that are having a baby soon so I thought a good Christmas gift to give them would be a subscription to a photo sharing web site so they could share all their photos of them and their new child. Since I have a Flickr pro [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=103&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Ok, so here is the story. I have some friends that are having a baby soon so I thought a good Christmas gift to give them would be a subscription to a photo sharing web site so they could share all their photos of them and their new child. Since I have a <a href="http://www.flickr.com/photos/lfoust/">Flickr pro account</a> and love it, I figured I would get them a Flickr account. But then I read about <a href="http://scobleizer.com/">Robert Scoble</a> raving about how <a href="http://scobleizer.com/2007/12/04/mugnormous/">much he loves Smugmug</a> and that he is possibly moving from <a href="http://www.flickr.com/">Flickr</a> to <a href="http://www.smugmug.com/">Smugmug</a>. So I decided to give Smugmug a try.</p>
<h3>On Trial</h3>
<p>So I signed up for a trial account with Smugmug and just browsed around to get a general feel for the site. I really like the site and they have a done a wonderful job of making it easy to perform most of the common tasks that a photo sharing site should enable you to do.</p>
<p>I talked it over with my wife and we both agreed that Flickr is more techy while Smugmug is more family friendly. Since we wanted a site which would allow our friends to share baby photos with their family, Smugmug seemed like a really good choice.</p>
<h3>A Snafu</h3>
<p>So I searched around the Smugmug site and finally found a page where you can &#8220;give the gift of Smugmug&#8221; so I decided I would go ahead with that. One problem though, when I reached the gifting page, I was greeted with a blank page. Hmmm. That&#8217;s strange. Maybe it is my browser. So I tried it in Firefox. Same thing. Try it for yourself, here is the Url:</p>
<p><a title="https://www.smugmug.com/gift.mg" href="https://www.smugmug.com/gift.mg">https://www.smugmug.com/gift.mg</a></p>
<p>Then, I remembered that Smugmug is a family owned business and they boast that they have really personal and friendly support. So I wrote those wonderful humans at <a href="mailto:help@smugmug.com">help@smugmug.com</a>.</p>
<h3>Warm, but not very helpful</h3>
<p>I wrote support and explained that I was getting a blank page in both browsers when trying to give the gift of Smugmug. I received a response a couple of days<strong><font color="#ff0000">*</font></strong> later that basically consisted of the usual support response: Clear your browser cache, delete all of your cookies, and restart your computer. Ok, that is to be expected. It seems that in technical support you have to start with the most basic things first. I knew it wouldn&#8217;t help but I decided to try it anyway. Well, it didn&#8217;t help. I was still getting a blank page.</p>
<p><strong><font color="#ff0000">*</font>Update</strong>: After going back and checking the timestamps on the emails with Smugmug support, the response actually came the next day and from then on out they responded to all of my emails within a couple of hours except for my very last message to them which was never responded to.</p>
<p>Next, I tried it at a different computer (from work) and again, in both browsers. Same results. So I replied to support and told them this and asked if they had any other ideas. The response I received really puzzled me:</p>
<blockquote><p>Thanks for contacting SmugMug. To give the &#8216;Gift of SmugMug&#8217; you must <br />have a current / active account with us and have credit card information <br />in the control panel of your account. Check to make sure you have <br />updates your account billing information.</p>
</blockquote>
<p>Well, I guess I don&#8217;t mind giving them my credit card information since I will need to be paying for this gift. So I went to my user settings on Smugmug and went to update my credit card information. Well, in order to enter credit card information, I must sign up for my own Smugmug account and pay for it. Ok, so let me get this straight. To give somebody else a gift, I must fist purchase an account for myself? But I am perfectly happy with my Flickr account and I don&#8217;t need to pay another fee for a site I may or may not use.</p>
<h3>In A Tight Spot</h3>
<p>So now here I am, three days after Christmas and I still have not been able to purchase a Christmas gift for my friends. My first reaction was to just back out and give them a Flickr account. But my wife insisted we get them a Smugmug account &#8211; it is prettier. So what do I do? At this point I don&#8217;t feel like I am getting much help from Smugmug. I am trying to give them money and they won&#8217;t take it.</p>
<h3>Why Blank?</h3>
<p>Ok, so maybe they haven&#8217;t really set up a way for non-members to give others gifts. Maybe this is even a business rule they decided to enforce on their web site. But why not explain this on the page rather than just giving me nothing? Here is what the code for that page must look like:</p>
<pre>if(User.IsPayingCustomer)
{
     DisplayGiftForm();
}
else
{
     DisplayBlankPage();
}</pre>
<p>Makes no sense to me. I must be missing something.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/103/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/103/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/103/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/103/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/103/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=103&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/12/29/why-wont-you-let-me-give-the-gift-of-smugmug/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>You Know You Are An Influential Blogger When&#8230;</title>
		<link>http://lfoust.wordpress.com/2007/12/13/you-know-you-are-an-influential-blogger-when/</link>
		<comments>http://lfoust.wordpress.com/2007/12/13/you-know-you-are-an-influential-blogger-when/#comments</comments>
		<pubDate>Thu, 13 Dec 2007 19:46:16 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/12/13/you-know-you-are-an-influential-blogger-when/</guid>
		<description><![CDATA[Sometimes it is hard to see threads of discussions in blog land because you may only be reading a subset of the blogs involved in the discussion. In this case, I just happened to be subscribed to many of the blogs in this thread. First let me lay out the timeline of posts: Jeff Atwood [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=102&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Sometimes it is hard to see threads of discussions in blog land because you may only be reading a subset of the blogs involved in the discussion. In this case, I just happened to be subscribed to many of the blogs in this thread. First let me lay out the timeline of posts:</p>
<blockquote><p>Jeff Atwood published his post <a href="http://www.codinghorror.com/blog/archives/001018.html" target="_blank">Sorting for Humans : Natural Sort Order</a></p>
<p>Ian Griffiths responds with post entitled <a href="http://www.interact-sw.co.uk/iangblog/2007/12/13/natural-sorting" target="_blank">Natural Sorting in C#</a></p>
<p>Charles Petzold responds with <a title="Sorting Without Spaces" href="http://www.charlespetzold.com/blog/2007/12/Sorting-Without-Spaces.html">Sorting Without Spaces</a></p>
<p>Dare Obasanjo responds with his post <a title="Natural Sort in IronPython vs. C# 2.0" href="http://www.25hoursaday.com/weblog/2007/12/13/NaturalSortInIronPythonVsC20.aspx">Natural Sort in IronPython vs. C# 2.0</a></p>
</blockquote>
<p>Now these are some pretty big names to have both reading your blog and responding on their own blog. And <a href="http://technorati.com/search/http%253A%252F%252Fwww.codinghorror.com%252Fblog%252Farchives%252F001018.html?sub=jscosmos" target="_blank">according to technorati, there are 9 blog reactions to Jeff&#8217;s post.</a> That is pretty impressive. That makes Jeff Atwood a very influential blogger in my book.</p>
<p>If this were my timeline, it would look more like this:</p>
<blockquote><p>Luke published his post on <a title="Asp.Net Control For Google Charts" href="http://blog.spontaneouspublicity.com/2007/12/09/aspnet-control-for-google-charts/">Asp.Net Control For Google Charts</a></p>
<p>Luke&#8217;s Mom emails him and says, &quot;I read your new blog post and I didn&#8217;t understand a word you said but great job!&quot;</p>
<p>Luke&#8217;s Wife calls him and says, &quot;Your Mom really likes your new blog post.&quot;</p>
<p>Trackback spam responds to Luke&#8217;s post: &quot;Want to buy some ViAGra?&quot;</p>
</blockquote>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/102/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/102/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/102/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=102&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/12/13/you-know-you-are-an-influential-blogger-when/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Productivity Tip: Copy As Path</title>
		<link>http://lfoust.wordpress.com/2007/12/10/productivity-tip-copy-as-path/</link>
		<comments>http://lfoust.wordpress.com/2007/12/10/productivity-tip-copy-as-path/#comments</comments>
		<pubDate>Mon, 10 Dec 2007 21:03:45 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Productivity Tip]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/12/10/productivity-tip-copy-as-path/</guid>
		<description><![CDATA[Here is a quick little tip I just learned that I use all of the time now. In Windows Vista, if you hold down the Shift key and right click on a file, a new option appears in the context menu: &#34;Copy As Path&#34; This will copy the full path of the file you select [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=101&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Here is a quick little tip I just learned that I use all of the time now. In Windows Vista, if you hold down the Shift key and right click on a file, a new option appears in the context menu: &quot;Copy As Path&quot;</p>
<p><img style="border-width:0;" height="480" alt="image" src="http://lfoust.files.wordpress.com/2007/12/image1.png?w=640&#038;h=480" width="640" border="0" /> </p>
<p>This will copy the full path of the file you select to the clipboard. This is very handy for pasting file paths into a command prompt window. Why this option is so hidden, I don&#8217;t know.</p>
<p>I hope this saves you some time.</p>
<p> <a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f12%2f10%2fproductivity-tip-copy-as-path%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f12%2f10%2fproductivity-tip-copy-as-path%2f" border="0" /></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/101/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/101/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/101/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/101/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/101/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/101/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/101/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/101/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/101/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/101/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=101&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/12/10/productivity-tip-copy-as-path/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/12/image1.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f12%2f10%2fproductivity-tip-copy-as-path%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>Finally &#8211; Asp.Net MVC</title>
		<link>http://lfoust.wordpress.com/2007/12/10/finally-aspnet-mvc/</link>
		<comments>http://lfoust.wordpress.com/2007/12/10/finally-aspnet-mvc/#comments</comments>
		<pubDate>Mon, 10 Dec 2007 20:15:26 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/12/10/finally-aspnet-mvc/</guid>
		<description><![CDATA[For those of you who have been following the new Asp.Net MVC (Model View Controller) framework know how much developers have been chomping at the bit (no pun intended) to try out new framework. Well, that day has finally arrived! ASP.NET 3.5 Extensions preview For those of you who haven&#8217;t been following the development of [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=99&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>For those of you who have been following the new Asp.Net MVC (Model View Controller) framework know how much developers have been chomping at the bit (no pun intended) to try out new framework. Well, that day has finally arrived!</p>
<p><a href="http://go.microsoft.com/fwlink/?LinkId=105896">ASP.NET 3.5 Extensions preview</a></p>
<p>For those of you who haven&#8217;t been following the development of this framework:</p>
<p><b>ASP.NET MVC</b> is an architecture that enables you to easily maintain separation of concerns in your applications, as well as facilitate clean testing and test driven development.</p>
<p>You can read some great articles on <a title="MVC Posts from Scott Guthrie" href="http://weblogs.asp.net/scottgu/archive/tags/MVC/default.aspx" target="_blank">Scott Guthrie&#8217;s blog</a> and <a title="MVC Posts from Rob Conery" href="http://blog.wekeroad.com/category/mvc/" target="_blank">Rob Conery&#8217;s</a> blog.</p>
<p>I definitely plan on checking it out and posting my thoughts and feedback.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/99/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/99/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/99/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=99&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/12/10/finally-aspnet-mvc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Asp.Net Control For Google Charts</title>
		<link>http://lfoust.wordpress.com/2007/12/09/aspnet-control-for-google-charts/</link>
		<comments>http://lfoust.wordpress.com/2007/12/09/aspnet-control-for-google-charts/#comments</comments>
		<pubDate>Sun, 09 Dec 2007 08:43:35 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Google Charts]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/12/09/aspnet-control-for-google-charts/</guid>
		<description><![CDATA[Google has launched a new service which allows you to very simply build charts for any web application. Their design decision to make an interface to their service which is all based on the format of the query string is very interesting to me. Basically, you send them a Url and they return a PNG [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=98&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Google has launched a new service which allows you to very simply build charts for any web application. Their design decision to make an interface to their service which is all based on the format of the query string is very interesting to me. Basically, you send them a Url and they return a PNG image of a chart. The <a href="http://code.google.com/apis/chart/" target="_blank">little query string language</a> they use for the charts is not the cleanest thing in the world but it is simple which is nice.</p>
<p>Here is the official description:</p>
<blockquote><p>The Google Chart API is an extremely simple tool that lets you easily create a chart from some data and embed it in a webpage. You embed the data and formatting parameters in an HTTP request, and Google returns a PNG image of the chart. Many types of chart are supported, and by making the request into an image tag you can simply include the chart in a webpage.</p></blockquote>
<h3>A Weekend Coding Project</h3>
<p>I really enjoy building custom Asp.Net web controls so I decided to try my hand at creating a control to wrap the Google chart functionality. Now, this is really just a first pass so it is definitely not bug free or feature complete. I just figure I can put it out there and get some feedback to see if I should continue in the same direction or to see if I am way off. Also, I can use this as an opportunity to share a little about how I approach web control design.</p>
<p>Note: I realize that I am <a href="http://pietschsoft.com/Blog/Post.aspx?PostID=1429" target="_blank">not the first or only one</a> to get the idea to create a Google chart Asp.Net control, but since my approach is so different, I figured I would go ahead and submit my own.</p>
<h3>So Many Classes</h3>
<p>Maybe I am a little too obsessive or just set in my ways, but it always seems like when I set out to tackle a problem like this, there is a set of helper/utility classes that I prefer to use. Over time this creates a sticky situation because I have so many copies of the same or similar classes laying around it becomes a maintenance nightmare. I have considered just creating my own utility assembly but then people would have to deploy that with any solution that they use my code in. I prefer to release my code as a self contained assembly whenever possible so I guess I will just put up with it for now.</p>
<p>Here is a quick list of the classes I used on this project:</p>
<p><img src="http://lfoust.files.wordpress.com/2007/12/image.png?w=194&#038;h=149" style="border-width:0;" alt="image" border="0" height="149" width="194" /></p>
<p>I use ColorHelper to translate System.Drawing.Color objects to and from their hexadecimal string counterparts. EnumHelper contains methods for getting Description attributes associated to enums as well as some parsing methods similar to <a href="http://devlicious.com/blogs/christopher_bennage/archive/2007/09/13/my-new-little-friend-enum-lt-t-gt.aspx" target="_blank">these</a>. I have written about <a href="http://blog.spontaneouspublicity.com/2007/05/22/delimitedlist-a-useful-utility-class/" target="_blank">DelimitedList</a> and the <a href="http://blog.spontaneouspublicity.com/2007/05/23/child-collections-in-aspnet-custom-controls/" target="_blank">state managed classes</a> before. I make heavy use of QueryStringHelper to build the query string which  represents the chart data.</p>
<h3>Heavy on the Declarative Syntax</h3>
<p>I have approached this problem by trying to represent the entire chart declaratively right in the aspx code. Here is an example of a line chart:</p>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">Chart</span> <span style="color:#ff0000;">ID</span><span style="color:#0000ff;">="chart"</span> <span style="color:#ff0000;">runat</span><span style="color:#0000ff;">="server"</span> <span style="color:#ff0000;">Width</span><span style="color:#0000ff;">="300px"</span> <span style="color:#ff0000;">Height</span><span style="color:#0000ff;">="150px"
</span>    <span style="color:#ff0000;">Title</span><span style="color:#0000ff;">="Transportation"</span> <span style="color:#ff0000;">Type</span><span style="color:#0000ff;">="Line"</span> <span style="color:#ff0000;">EnableLegend</span><span style="color:#0000ff;">="true"&gt;
</span>    <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">DataSets</span><span style="color:#0000ff;">&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataSet</span> <span style="color:#ff0000;">Color</span><span style="color:#0000ff;">="ForestGreen"</span> <span style="color:#ff0000;">Label</span><span style="color:#0000ff;">="Cars"&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="5"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="9"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="21"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="30"</span> <span style="color:#ff0000;">Marker</span><span style="color:#0000ff;">="Arrow"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="25"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="36"</span> <span style="color:#0000ff;">/&gt;
</span>        <span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataSet</span><span style="color:#0000ff;">&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataSet</span> <span style="color:#ff0000;">Color</span><span style="color:#0000ff;">="Red"</span> <span style="color:#ff0000;">Label</span><span style="color:#0000ff;">="Trucks"&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="7"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="3"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="13"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="13"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="16"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="25"</span> <span style="color:#0000ff;">/&gt;
</span>        <span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataSet</span><span style="color:#0000ff;">&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataSet</span> <span style="color:#ff0000;">Color</span><span style="color:#0000ff;">="Orange"</span> <span style="color:#ff0000;">Label</span><span style="color:#0000ff;">="Motorcycles"&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="18"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="25"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="18"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="13"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="25"</span> <span style="color:#0000ff;">/&gt;
</span>            <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataPoint</span> <span style="color:#ff0000;">Value</span><span style="color:#0000ff;">="23"</span> <span style="color:#0000ff;">/&gt;
</span>        <span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">DataSet</span><span style="color:#0000ff;">&gt;
</span>    <span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">DataSets</span><span style="color:#0000ff;">&gt;
&lt;/</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">Chart</span><span style="color:#0000ff;">&gt;</span></pre>
<p>As you can see, a chart with any sizable amount of data can become very cumbersome. The output of this chart looks like this:</p>
<p><img src="http://chart.apis.google.com/chart?chd=t%3a5%2c9%2c21%2c30%2c25%2c36%7c7%2c3%2c13%2c13%2c16%2c25%7c18%2c25%2c18%2c13%2c25%2c23&amp;cht=lc&amp;chs=300x150&amp;chco=228b22%2cff0000%2cffa500&amp;chm=a%2c000000%2c0%2c3%2c10&amp;chtt=Transportation&amp;chdl=Cars%7cTrucks%7cMotorcycles" alt="Transportation" /></p>
<p>The url used to generate this chart looks like this:</p>
<p>http://chart.apis.google.com/chart?chd=t:5,9,21,30,25,36|7,3,13,13,16,25|18,25,18,13,25,23</p>
<p>&amp;cht=lc&amp;chs=300&#215;150&amp;chco=228b22,ff0000,ffa500<br />
&amp;chm=a,000000,0,3,10&amp;chtt=Transportation&amp;chdl=Cars|Trucks|Motorcycles</p>
<p>You can change the type of chart being generated through the Type property. Here is an example of a bar chart:</p>
<p><img src="http://chart.apis.google.com/chart?chd=t%3a68%2c78%2c88%7c68%2c58%2c78%7c88%2c48%2c98&amp;cht=bvg&amp;chs=400x100&amp;chco=b22222%2c006400%2cff8c00&amp;chxt=y&amp;chf=c%2cls%2c90%2cffffff%2c0.25%2cd3d3d3%2c0.25&amp;chdl=Men%7cWomen%7cBoth" /></p>
<p>A Venn Diagram:</p>
<p><img src="http://chart.apis.google.com/chart?chd=t%3a100%2c80%2c60%2c30%2c30%2c10&amp;cht=v&amp;chs=250x100&amp;chdl=What+I+Know%7cWhat+I+Think+I+Know%7cWhat+I+Actually+Know" /></p>
<p>Pie Chart:</p>
<p><img src="http://chart.apis.google.com/chart?chd=t%3a50%2c30%2c20&amp;cht=p3&amp;chs=250x100&amp;chco=b22222&amp;chl=Men%7cWomen%7cChildren" /></p>
<h3>Feedback Please</h3>
<p>What I really need right now is some feedback. Do you find this helpful at all? Is my design way off? What would be the ideal way to build charts using the Google Api?</p>
<p>Please &#8211; download the library, try it out. Download the source and check it out. Post comments letting me know what you think.</p>
<p>Also, let me know if you would like me to write more about the details of the code or the usage of the control.</p>
<p>Source: <a href="http://www.spontaneouspublicity.com/Downloads/Web.Google.Chart-source.zip" title="Google Chart Source">Google Chart Source</a> Assembly: <a href="http://www.spontaneouspublicity.com/Downloads/Web.Google.Chart-binary.zip" title="Google Chart Assembly" target="_blank">Google Chart Assembly</a></p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f12%2f09%2faspnet-control-for-google-charts%2f"><img src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f12%2f09%2faspnet-control-for-google-charts%2f" alt="kick it on DotNetKicks.com" border="0" /></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/98/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/98/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/98/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/98/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/98/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/98/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/98/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/98/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/98/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/98/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=98&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/12/09/aspnet-control-for-google-charts/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/12/image.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://chart.apis.google.com/chart?chd=t%3a5%2c9%2c21%2c30%2c25%2c36%7c7%2c3%2c13%2c13%2c16%2c25%7c18%2c25%2c18%2c13%2c25%2c23&#38;cht=lc&#38;chs=300x150&#38;chco=228b22%2cff0000%2cffa500&#38;chm=a%2c000000%2c0%2c3%2c10&#38;chtt=Transportation&#38;chdl=Cars%7cTrucks%7cMotorcycles" medium="image">
			<media:title type="html">Transportation</media:title>
		</media:content>

		<media:content url="http://chart.apis.google.com/chart?chd=t%3a68%2c78%2c88%7c68%2c58%2c78%7c88%2c48%2c98&#38;cht=bvg&#38;chs=400x100&#38;chco=b22222%2c006400%2cff8c00&#38;chxt=y&#38;chf=c%2cls%2c90%2cffffff%2c0.25%2cd3d3d3%2c0.25&#38;chdl=Men%7cWomen%7cBoth" medium="image" />

		<media:content url="http://chart.apis.google.com/chart?chd=t%3a100%2c80%2c60%2c30%2c30%2c10&#38;cht=v&#38;chs=250x100&#38;chdl=What+I+Know%7cWhat+I+Think+I+Know%7cWhat+I+Actually+Know" medium="image" />

		<media:content url="http://chart.apis.google.com/chart?chd=t%3a50%2c30%2c20&#38;cht=p3&#38;chs=250x100&#38;chco=b22222&#38;chl=Men%7cWomen%7cChildren" medium="image" />

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f12%2f09%2faspnet-control-for-google-charts%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>Productivity tip: Visual Studio Smart Tags</title>
		<link>http://lfoust.wordpress.com/2007/11/10/productivity-tip-visual-studio-smart-tags/</link>
		<comments>http://lfoust.wordpress.com/2007/11/10/productivity-tip-visual-studio-smart-tags/#comments</comments>
		<pubDate>Sat, 10 Nov 2007 18:27:46 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Productivity Tip]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/11/10/productivity-tip-visual-studio-smart-tags/</guid>
		<description><![CDATA[In Visual Studio 2005 they added a feature that is very useful &#8211; when you type the name of a class, if you have the assembly for that class referenced but you don&#8217;t yet have a using tag in your file, it can add it for you. This is accomplished using a Smart Tag (much [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=96&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In Visual Studio 2005 they added a feature that is very useful &#8211; when you type the name of a class, if you have the assembly for that class referenced but you don&#8217;t yet have a using tag in your file, it can add it for you. This is accomplished using a Smart Tag (much like the smart tags in Microsoft Office). The one problem is that if you are typing and the smart tag comes up, you have to use the mouse to click on it and choosing an option.</p>
<p>When you first type the word (which is case sensitive)</p>
<p><img height="48" alt="SmartTag01" src="http://lfoust.files.wordpress.com/2007/11/smarttag01.png?w=227&#038;h=48" width="227" /></p>
<p>Then you put your mouse over the little blip and you get:</p>
<p><a href="http://lfoust.files.wordpress.com/2007/11/smarttag02.png"><img style="border-width:0;" height="57" alt="SmartTag02" src="http://lfoust.files.wordpress.com/2007/11/smarttag02-thumb.png?w=168&#038;h=57" width="168" border="0" /></a></p>
<p>Then you click and you get the menu:</p>
<p><img style="border-width:0;" height="126" alt="SmartTag03" src="http://lfoust.files.wordpress.com/2007/11/smarttag03.png?w=405&#038;h=126" width="405" border="0" /></p>
<p>My point is that this is all a very disruptive if you just want to quickly add the using tag and keep moving. I should mention, that there is a default keyboard binding to show the smart tag menu which is Alt+Shift+F10. Personally I can never remember this short cut.</p>
<h3>So what is the tip already?</h3>
<p>What I like to do is to bind this shortcut to a more intuitive Alt+Down Arrow. This way I just hold down the alt button and pressing down makes sense that the menu would show.</p>
<p>To set this binding you must open up the Tools-&gt;Options menu in Visual Studio and go to the &#8216;Keyboard&#8217; tab. In the commands box, type in &#8216;View.ShowSmartTag&#8217; and you will see the command show up in the list:</p>
<p><img style="border-width:0;" height="293" alt="" src="http://lfoust.files.wordpress.com/2007/11/sshot-5.png?w=504&#038;h=293" width="504" border="0" /></p>
<p>Then, put your cursor in the Shortcut key box and press Alt+The Down Arrow. Click assign and OK and you are all good to go.</p>
<p>Now to add a using statement, you just have to type the class name, type Alt+Down Arrow, and press enter. Not very disruptive at all. This may seem small but I find this to be extremely useful in my day to day development.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/96/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/96/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/96/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/96/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/96/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/96/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/96/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/96/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/96/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/96/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=96&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/11/10/productivity-tip-visual-studio-smart-tags/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/11/smarttag01.png" medium="image">
			<media:title type="html">SmartTag01</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/11/smarttag02-thumb.png" medium="image">
			<media:title type="html">SmartTag02</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/11/smarttag03.png" medium="image">
			<media:title type="html">SmartTag03</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/11/sshot-5.png" medium="image" />
	</item>
		<item>
		<title>Life Changes So Fast</title>
		<link>http://lfoust.wordpress.com/2007/10/11/life-changes-so-fast/</link>
		<comments>http://lfoust.wordpress.com/2007/10/11/life-changes-so-fast/#comments</comments>
		<pubDate>Thu, 11 Oct 2007 23:25:13 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/10/11/life-changes-so-fast/</guid>
		<description><![CDATA[If Scott Hanselman and Phil Haack can do it then why can&#8217;t I? That&#8217;s right, I am joining Microsoft on the Windows reliability team as an SDET. The craziest part is it has all happened so fast that I am not sure the best way to prepare to move from San Diego to Washington in [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=90&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>If <a href="http://www.hanselman.com/blog/BlueBadge.aspx" target="_blank">Scott Hanselman</a> and <a href="http://haacked.com/archive/2007/09/17/why-is-microsoft-removing-my-mvp-status.aspx" target="_blank">Phil Haack</a> can do it then why can&#8217;t I? That&#8217;s right, I am joining Microsoft on the Windows reliability team as an <a title="Software Design Engineer in Test" href="http://members.microsoft.com/careers/careerpath/technical/softwaretesting.mspx" target="_blank">SDET</a>. The craziest part is it has all happened so fast that I am not sure the best way to prepare to move from San Diego to Washington in two weeks.</p>
<p>I am very excited about this opportunity to grow and work in an area that is outside of my usual expertise. Just in case you are not clear about exactly what and SDET does or if you had some of the same misconceptions I did, here are a couple of posts&nbsp;from <a href="http://blogs.msdn.com/jobsblog/" target="_blank">jobsblog</a>&nbsp;to clear things up:</p>
<ul>
<li><a title="SDET/Testers - Behind the Myths" href="http://blogs.msdn.com/jobsblog/archive/2007/06/13/sdet-testers-behind-the-myths.aspx">SDET/Testers &#8211; Behind the Myths</a></li>
<li><a title="Are you a good enough developer to be a Microsoft SDET?" href="http://blogs.msdn.com/jobsblog/archive/2004/05/27/143419.aspx" target="_blank">Are you a good enough developer to be a Microsoft SDET?</a></li>
</ul>
<p>I am not sure what this move will mean for the future content of this blog. I plan on keeping up with all things .Net even though I will be taking a new journey into the land of unmanaged code.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/90/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/90/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/90/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/90/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/90/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/90/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/90/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/90/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/90/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/90/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=90&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/10/11/life-changes-so-fast/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Is Ruby the new Perl?</title>
		<link>http://lfoust.wordpress.com/2007/09/19/is-ruby-the-new-perl/</link>
		<comments>http://lfoust.wordpress.com/2007/09/19/is-ruby-the-new-perl/#comments</comments>
		<pubDate>Wed, 19 Sep 2007 19:27:21 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/09/19/is-ruby-the-new-perl/</guid>
		<description><![CDATA[I just now completed the ruby tutorial over at try ruby! and I couldn&#8217;t help but think how much ruby is like Perl. My first programming jobs in college were using mostly Perl so I have some (mostly) fond memories of how easy Perl made some tasks. I know I am late to the party when [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=89&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I just now completed the ruby tutorial over at <a href="http://tryruby.hobix.com/">try ruby!</a> and I couldn&#8217;t help but think how much ruby is like Perl. My first programming jobs in college were using mostly Perl so I have some (mostly) fond memories of how easy Perl made some tasks.</p>
<p>I know I am late to the party when it comes to checking out ruby. I just don&#8217;t really have alot of opportunity to use it outside of my free time. I finally decided to answer the <a href="http://www.hanselman.com/blog/WhyWouldANETProgrammerLearnRubyOnRails.aspx">call of Scott Hanselman</a> and try it out. Just like Perl made working with text files and regular expressions really simple, ruby (and more specifically, rails), seems to do that for web development. I plan on spending alot more time looking into ruby/rails but I just wanted to share my initial thoughts.</p>
<p>I can remember doing things like:</p>
<pre>open(FILE) or die "cant open file";</pre>
<p>in perl and when I see:</p>
<pre>Time.now - 2.weeks</pre>
<p>in ruby it takes me back to those days.</p>
<p>I was just recently talking to a recruiter who was looking for Perl developers. I was really surprised that new startups are actually choosing technologies like Perl when things like ruby on rails exist.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/89/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/89/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/89/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/89/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/89/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/89/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/89/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/89/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/89/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/89/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=89&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/09/19/is-ruby-the-new-perl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Asp.Net Ajax: How do you know all of your Ajax calls have completed?</title>
		<link>http://lfoust.wordpress.com/2007/08/22/aspnet-ajax-how-do-you-know-all-of-your-ajax-calls-have-completed/</link>
		<comments>http://lfoust.wordpress.com/2007/08/22/aspnet-ajax-how-do-you-know-all-of-your-ajax-calls-have-completed/#comments</comments>
		<pubDate>Wed, 22 Aug 2007 17:24:18 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Ajax]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/08/22/aspnet-ajax-how-do-you-know-all-of-your-ajax-calls-have-completed/</guid>
		<description><![CDATA[Some Background Here is a situation I ran into recently: I have an Asp.Net Ajax service (.asmx) which has a method used to create rows in a database similiar to: [WebMethod] public int CreateItem(string description, double value) This method basically created a row in the database and returns the id of the item created. It [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=87&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[</p>
<h3>Some Background</h3>
<p>Here is a situation I ran into recently: I have an Asp.Net Ajax service (.asmx) which has a method used to create rows in a database similiar to:</p>
<pre>[<span style="color:rgb(43,145,175);">WebMethod</span>]
<span style="color:rgb(0,0,255);">public</span> <span style="color:rgb(0,0,255);">int</span> CreateItem(<span style="color:rgb(0,0,255);">string</span> description, <span style="color:rgb(0,0,255);">double</span> value)
</pre>
<p>This method basically created a row in the database and returns the id of the item created. It is called from javascript like this:</p>
<pre><span style="color:rgb(0,0,255);">function</span> MyButtonClicked() {
    MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My Item"</span>, 5.3, OnSucceeded, OnFailed);
}

<span style="color:rgb(0,0,255);">function</span> OnSucceeded(result, userContext, methodName) {
}

<span style="color:rgb(0,0,255);">function</span> OnFailed(error, userContext, methodName) {
}
</pre>
<p>If you are not familiar with calling Ajax web services from javascript, you can read more from the <a href="http://asp.net/ajax/documentation/live/tutorials/ConsumingWebServicesWithAJAXTutorial.aspx" target="_blank">Calling Web Services from Client Script in ASP.NET AJAX</a>&nbsp;article on asp.net. Basically, I am just calling my <strong>CreateItem</strong> method (which is part of a .asmx service) from javascript &#8211; how this magic happens isn&#8217;t really too important to understand the problem I was facing.</p>
<p>Notice that the last two parameters I passed into my <strong>CreateItem</strong> call in javascript are references to callback methods that should be called in the event that my call succeeded or failed. A successful call will end up calling back my OnSucceeded method which has 3 parameters:</p>
<ul>
<li><strong>result</strong> &#8211; this contains any values returned from my method. In this case it will be the id of the item that was inserted.</li>
<li><strong>userContext</strong> &#8211; this is an optional item that can be passed into the original call to the method and will just be passed on to the callback method. I am not using this parameter in this situation</li>
<li><strong>methodName</strong> &#8211; this is the name of the method that was called which resulted in the <strong>OnSucceeded</strong> method being called. In my case, this will be the string <font color="#008000">&#8220;CreateItem&#8221;</font></li>
</ul>
<h3>Now for the Problem</h3>
<p>Ok, now with all that background I can actually spell out the problem I had to solve. In many cases, I make calls to the <strong>CreateItem</strong> method many times in a row. So if I need to create three items in the database, I may do something like this in javascript:</p>
<pre>MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My first Item"</span>, 1, OnSucceeded, OnFailed);
MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My second Item"</span>, 2, OnSucceeded, OnFailed);
MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My third Item"</span>, 3, OnSucceeded, OnFailed);
</pre>
<p>Notice that all three calls have the same callback on success. Now lets say I want to create these three items and then as soon as all three calls are completed successfully I want to forward the user to another page. At first you may think I can just do something like this:</p>
<pre><span style="color:rgb(0,0,255);">function</span> OnSucceeded(result, userContext, methodName) {
    <span style="color:rgb(0,0,255);">if</span> (methodName == <span style="color:rgb(128,0,0);">"CreateItem"</span>) {
        window.location = <span style="color:rgb(128,0,0);">"NextPage.aspx";
</span>    }
}
</pre>
<p>This would forward the user to a new page as soon as our call to <strong>CreateItem</strong> has completed successfully. There is one huge problem though: how do we know which call to <strong>CreateItem</strong> succeeded? The first one? The Second one? The third one?</p>
<p>Obviously we only want to forward the user in the case that our final call has succeeded. As you can see, this problem only gets worse if we have other calls on the same page that could be pending at the time we want to forward the user to the next page.</p>
<h3>My Solution &#8211; Count Your Calls</h3>
<p>So here is how I solved the problem: I made a variable which I would use to keep track of how many pending calls there were at any given time. At the top of my javascript page I first declare:</p>
<pre><span style="color:rgb(0,0,255);">var</span> pendingCalls = 0;
</pre>
<p>Then, each time I make a call, I increment the counter:</p>
<pre>++pendingCalls;
MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My first Item"</span>, 1, OnSucceeded, OnFailed);
++pendingCalls;
MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My second Item"</span>, 2, OnSucceeded, OnFailed);
++pendingCalls;
MyNamespace.Service.CreateItem(<span style="color:rgb(128,0,0);">"My third Item"</span>, 3, OnSucceeded, OnFailed);
</pre>
<p>Then I need to make sure I decrement the counter each time a call succeeds or fails:</p>
<pre><span style="color:rgb(0,0,255);">function</span> OnSucceeded(result, userContext, methodName) {
    --pendingCalls;
}

<span style="color:rgb(0,0,255);">function</span> OnFailed(error, userContext, methodName) {
    --pendingCalls;
}
</pre>
<p>This way, we know how many pending calls we have at any given time. Then to forward the user to a new page once all calls are completed, I did the following:</p>
<pre><span style="color:rgb(0,0,255);">function</span> OnSucceeded(result, userContext, methodName) {
    --pendingCalls;
    <span style="color:rgb(0,0,255);">if</span> (methodName == <span style="color:rgb(128,0,0);">"CreateItem"</span> &amp;&amp; pendingCalls == 0) {
        window.location = <span style="color:rgb(128,0,0);">"NextPage.aspx"</span>;
    }
}
</pre>
<p>As you can see, asynchronous programming can be very difficult. Has anybody else had to solve this problem? If so, how did you do it?</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/87/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/87/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/87/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/87/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/87/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=87&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/08/22/aspnet-ajax-how-do-you-know-all-of-your-ajax-calls-have-completed/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Using JQuery to Make Asp.Net Play Nice with Asp.Net</title>
		<link>http://lfoust.wordpress.com/2007/08/20/using-jquery-to-make-aspnet-play-nice-with-aspnet/</link>
		<comments>http://lfoust.wordpress.com/2007/08/20/using-jquery-to-make-aspnet-play-nice-with-aspnet/#comments</comments>
		<pubDate>Mon, 20 Aug 2007 22:54:31 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Ajax]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/08/20/using-jquery-to-make-aspnet-play-nice-with-aspnet/</guid>
		<description><![CDATA[I have found that developing an Asp.Net application that makes heavy use of javascript is very difficult. One of the major pain points is dealing with the horrendously long ids that Asp.Net server controls generates. For example, the following Asp.Net markup: &#60;asp:TextBox ID="myTextBox" runat="server" /&#62; can cause the TextBox to be rendered as: &#60;input name="ctl00$ContentPlaceHolder1$myTextBox" [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=86&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have found that developing an Asp.Net application that makes heavy use of javascript is very difficult. One of the major pain points is dealing with the horrendously long ids that Asp.Net server controls generates. For example, the following Asp.Net markup:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">asp</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">TextBox</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="myTextBox"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"><a href="http://11011.net/software/vspaste"></a></p>
<p>can cause the TextBox to be rendered as:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">input</span> <span style="color:rgb(255,0,0);">name</span><span style="color:rgb(0,0,255);">="ctl00$ContentPlaceHolder1$myTextBox"</span>
    <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text"</span> <span style="color:rgb(255,0,0);">id</span><span style="color:rgb(0,0,255);">="ctl00_ContentPlaceHolder1_myTextBox"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>if the page uses a <a href="http://msdn2.microsoft.com/en-us/library/wtxbf3hh.aspx" target="_blank">MasterPage</a> or any moderately complex control hierarchy. Asp.Net does this to minimize naming conflicts. This is the whole concept of a Naming Container. Asp.Net uses the interface <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.inamingcontainer.aspx" target="_blank">INamingContainer</a> to mark controls that can be rendered inside of a naming container. The end result is a really long id that can change based on the items place in the control hierarchy. This is a problem if you want to use the elements rendered by server controls in your client side javascript code.</p>
<h3>First, the Hack</h3>
<p>One technique for getting around this I have seen, has a definite bad code smell to it. You basically have Asp.Net render the itemsID inside your javascript code using the &lt;% %&gt; syntax like so:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">script</span> <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text/javascript"&gt;
</span>    var myValue = document.getElementById(<span style="color:rgb(128,0,0);">'&lt;%= myTextBox.ClientID %&gt;'</span>);
<span style="color:rgb(0,0,255);">&lt;/</span><span style="color:rgb(163,21,21);">script</span><span style="color:rgb(0,0,255);">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>this will render as</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">script</span> <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text/javascript"&gt;
</span>    var myValue = document.getElementById(<span style="color:rgb(128,0,0);">'ctl00_ContentPlaceHolder1_myTextBox'</span>);
<span style="color:rgb(0,0,255);">&lt;/</span><span style="color:rgb(163,21,21);">script</span><span style="color:rgb(0,0,255);">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>This technique has a couple of huge short commings:</p>
<ul>
<li>It is really hard to maintain</li>
<li>It doesn&#8217;t support having your javascript in a library or a separte .js file</li>
</ul>
<h3>JQuery to the Rescue&#8230;sort of</h3>
<p>There are many javascript client libraries out there that help ease the headache of writing javascript code that works across browsers. I am currently working on a project where we have decided to use <a href="http://jquery.com/" target="_blank">JQuery</a> which I am very impressed with. </p>
<p>One of the main features of using the JQuery library, is its use of selectors to find elements on the page. I will not get that deeply into this rich DOM querying language here, but you can read all about it from the <a href="http://docs.jquery.com/Selectors" target="_blank">JQuery Documentation</a>.</p>
<p>JQuery selectors allow me to find items in the page many different ways. For example, I can find the textbox in my example above using the following code:</p>
<pre>var myTextBox = $(<span style="color:rgb(128,0,0);">"input:text"</span>);</pre>
<p>This will actually find every textbox on the page but since we have only on textbox on our page, it works. Alternatively, you can use something like the Css class of the item. Suppose we gave the textbox a css class of &#8216;textInput&#8217;:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">asp</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">TextBox</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="myTextBox"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(255,0,0);">CssClass</span><span style="color:rgb(0,0,255);">="textInput"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>Now, the control renders as</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">input</span> <span style="color:rgb(255,0,0);">name</span><span style="color:rgb(0,0,255);">="ctl00$ContentPlaceHolder1$myTextBox"</span>
    <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text"</span> <span style="color:rgb(255,0,0);">id</span><span style="color:rgb(0,0,255);">="ctl00_ContentPlaceHolder1_myTextBox"</span>
    <span style="color:rgb(255,0,0);">class</span><span style="color:rgb(0,0,255);">="textInput"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p>so we can use JQuery to select just this item using the following javascript
<pre>var myTextBox = $(<span style="color:rgb(128,0,0);">"input:text[@class=textInput]"</span>);</pre>
<p>or
<pre>var myTextBox = $(<span style="color:rgb(128,0,0);">"input.textInput"</span>);</pre>
<p><a href="http://11011.net/software/vspaste"></a>or even simpler
<pre>var myTextBox = $(<span style="color:rgb(128,0,0);">".textInput"</span>);</pre>
<p><a href="http://11011.net/software/vspaste"></a>There are many ways to select the same item, but you get the idea.</p>
<p>So does this solve our problem with long IDs? No, not really, we would still have to use the following javascript to select this item by id:</p>
<pre>var myTextBox = $(<span style="color:rgb(128,0,0);">"#ctl00_ContentPlaceHolder1_myTextBox"</span>);</pre>
<h3>The Solution</h3>
<p>As I was working through this problem in my head, I&nbsp;remembered somethign about javascript: it is more than&nbsp;just the attributes that&nbsp;already exist in DOM elements. You are not restricted to just using ID or Class. So why not&nbsp;just come&nbsp;up with your own attribute to use just for the purpose of selecting DOM elements?&nbsp;So here is a pretty workable solution I came up with:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">asp</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">TextBox</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="myTextBox"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(255,0,0);">ClientSelector</span><span style="color:rgb(0,0,255);">="myTextBox"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p>I just use a made up attribute called &#8216;ClientSelector&#8217; (you can use whatever you fancy and it renders like this:
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">input</span> <span style="color:rgb(255,0,0);">name</span><span style="color:rgb(0,0,255);">="ctl00$ContentPlaceHolder1$myTextBox"</span> <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text"</span>
    <span style="color:rgb(255,0,0);">id</span><span style="color:rgb(0,0,255);">="ctl00_ContentPlaceHolder1_myTextBox"</span>
    <span style="color:rgb(255,0,0);">ClientSelector</span><span style="color:rgb(0,0,255);">="myTextBox"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p>so now we can use JQuery to select the item with this statement
<pre>var myTextBox = $(<span style="color:rgb(128,0,0);">"input[@ClientSelector=myTextBox]"</span>);</pre>
<p>So now we can use the same selector for just this one textbox no matter if it is in a MasterPage or not. We don&#8217;t have to care how the id renders anymore. I have found this technique very useful. What do you think? Is this also too much of a hack?</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/86/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/86/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/86/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=86&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/08/20/using-jquery-to-make-aspnet-play-nice-with-aspnet/feed/</wfw:commentRss>
		<slash:comments>36</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Microsoft Ajax Enabled Web Site Organization Patterns</title>
		<link>http://lfoust.wordpress.com/2007/08/01/microsoft-ajax-enabled-web-site-organization-patterns/</link>
		<comments>http://lfoust.wordpress.com/2007/08/01/microsoft-ajax-enabled-web-site-organization-patterns/#comments</comments>
		<pubDate>Wed, 01 Aug 2007 15:12:40 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Ajax]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/08/01/microsoft-ajax-enabled-web-site-organization-patterns/</guid>
		<description><![CDATA[Lately I have been writing a lot of code utilizing the Microsoft Ajax framework. This means that I am writing &#8220;Ajax Services&#8221; to handle my asynchronous callbacks. Ajax Services is a term I heard from Rob Bagby which emphasizes the fact that while these services are generally in a .asmx file and the methods are [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=85&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[</p>
<p>Lately I have been writing a lot of code utilizing the <a href="http://asp.net/ajax/" target="_blank">Microsoft Ajax framework</a>. This means that I am writing &#8220;Ajax Services&#8221; to handle my asynchronous callbacks. Ajax Services is a term I heard from <a href="http://blogs.msdn.com/bags/" target="_blank">Rob Bagby</a> which emphasizes the fact that while these services are generally in a .asmx file and the methods are decorated with the [WebMethod] attribute, they are not really web services. They are a special form of service made just for Ajax callbacks. This additional file has got me thinking lately about how I can organize the files in my web site so that it doesn&#8217;t get too cluttered.</p>
<p>Let me start off by saying that this post is just a diary of my thoughts and I don&#8217;t really think I have found the best solution yet. That is why I am putting this out there to see how others are approaching this situation.</p>
<h3>Too Many Files</h3>
<p><img height="73" alt="File Orginization" src="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization01.png" width="137" align="left"> In extreme cases, I can have four different separate files (6 if you count the code behind file) for just one page. Typically, you have one javascript file and one css file per website but I have found this to just be too cumbersome lately. I find that my css and js files just become too cluttered and hard to maintain. So I end up with:</p>
<ul>
<li>.asmx &#8211; Contains the WebMethods for my ajax callbacks</li>
<li>.aspx &#8211; Contains the layout for my page in typically Asp.Net fasion</li>
<li>.css &#8211; Contains the style definitions for the page layout</li>
<li>.js &#8211; Contains the javascript methods which typically respond to events on my page and make callbacks to my ajax services.</li>
</ul>
<p>So now lets look at a folder on the website which has 3 different pages &#8211; a very typical scenario.</p>
<p><img height="217" alt="Too many files!" src="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization02.png" width="140"> </p>
<p>This layout quickly becomes unwieldy in its own way. All of the sudden your solution explorer view of your site becomes very hard to navigate and it becomes difficult to maintain the references to all those files. Now if I have a very simple page which has no need for any ajax callbacks or custom css mixed in there, It sort of gets lost in the shuffle</p>
<p><img style="border-right:0;border-top:0;border-left:0;border-bottom:0;" height="217" alt="Lost in the Shuffle" src="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization04.png" width="175" border="0"> </p>
<p>See how your eye can easily miss the &#8216;MyPage2-Simple.aspx&#8217; page?</p>
<h3>A Better Way?</h3>
<p>Another idea I had was to have one folder per page which would look like:</p>
<p><img style="border-right:0;border-top:0;border-left:0;border-bottom:0;" height="269" alt="Is this better?" src="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization03.png" width="170" border="0"> </p>
<p>This is a little better but it is still cluttered. Just for completeness, lets look at our site with only one js, css, and asmx file.</p>
<p><img style="border-right:0;border-top:0;border-left:0;border-bottom:0;" height="109" alt="Cleaner?" src="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization05.png" width="142" border="0"> </p>
<p>While this definitely looks a lot cleaner, it also has a <a href="http://en.wikipedia.org/wiki/Code_smell" target="_blank">code smell</a> of it&#8217;s own. Imagine what our common files (js, css, asmx) must look like. They have the code from 3 separate pages all thrown in together.</p>
<p>The last idea I will throw out there is to put each file type in its own folder.</p>
<p><img height="270" alt="Grouped Together" src="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization06.png" width="170"> </p>
<p>I also like this better than most but it breaks down pretty quickly when you have your web site organized into many folders. Do you keep the script, service, and style files in the root folders or do you have a Script, Services, and Style folder for each sub folder?</p>
<p>Like I said earlier, I haven&#8217;t really found a solution that I think is best. Currently, I am trying to organize my project by having each action in its own folder and within these folders I put all the extra files (style, script, or callbacks).</p>
<p>How do you organize your web sites? How do you&nbsp;non Asp.Net people organize yours?</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/85/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/85/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/85/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/85/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/85/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/85/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/85/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/85/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/85/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/85/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=85&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/08/01/microsoft-ajax-enabled-web-site-organization-patterns/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization01.png" medium="image">
			<media:title type="html">File Orginization</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization02.png" medium="image">
			<media:title type="html">Too many files!</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization04.png" medium="image">
			<media:title type="html">Lost in the Shuffle</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization03.png" medium="image">
			<media:title type="html">Is this better?</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization05.png" medium="image">
			<media:title type="html">Cleaner?</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/08/fileorginization06.png" medium="image">
			<media:title type="html">Grouped Together</media:title>
		</media:content>
	</item>
		<item>
		<title>Addictive Applications</title>
		<link>http://lfoust.wordpress.com/2007/07/23/addictive-applications/</link>
		<comments>http://lfoust.wordpress.com/2007/07/23/addictive-applications/#comments</comments>
		<pubDate>Mon, 23 Jul 2007 16:06:21 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/07/23/addictive-applications/</guid>
		<description><![CDATA[I made the mistake of reading this post from Jeff Atwood&#8217;s blog Coding Horror. What was the mistake? Well, it was clicking on the link to Geni &#8211; a family collaboration site. Not only did the developers at Geni remove the login barrier, they also made a very addictive application. So go ahead. Do it. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=77&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I made the mistake of reading <a href="http://www.codinghorror.com/blog/archives/000881.html" target="_blank">this post</a> from <a href="http://www.codinghorror.com/blog/archives/000021.html" target="_blank">Jeff Atwood&#8217;s</a> blog <a href="http://www.codinghorror.com/blog/" target="_blank">Coding Horror</a>. What was the mistake? Well, it was clicking on the link to <a href="http://www.geni.com/" target="_blank">Geni</a> &#8211; a family collaboration site. Not only did the developers at <a href="http://www.geni.com/" target="_blank">Geni</a> remove the login barrier, they also made a very addictive application.</p>
<p>So go ahead. Do it. Click on the link. And then come back in an hour or so and read the rest of this post if you can stop trying to remember your uncles third cousins middle name.</p>
<p>I have shared this site with several people and they all have the same reaction &#8211; they immediately start adding all of the family members they can think of and they usually get 20 or 30 people deep before they stop. What is it about Geni that is so addictive? Well I think there are several things:</p>
<ul>
<li>It is extremely easy to start</li>
<li>The main interface is graphical and immediately makes sense.</li>
<li>Collaboration is encouraged</li>
<li>Users are encouraged to contribute</li>
<li>It is applicable to a wide array of users</li>
</ul>
<h3>Easy to Start</h3>
<p><a href="http://lfoust.files.wordpress.com/2007/07/treestart.png" target="_blank"><img src="http://lfoust.files.wordpress.com/2007/07/treestart-thumb.png?w=240&#038;h=165" alt="Easy to Start" width="240" height="165" align="left" /></a></p>
<p>When you first visit Geni, the interface is just inviting you to start inputting information just to see what happens. I don&#8217;t want to repeat too much of what Jeff said in his post, but when it is this easy to start (and you aren&#8217;t asked for tons of irrelevent information up front) I think users are much more likely to sign up. In addition to being easy, the initialy start page is does not force you to do something that you don&#8217;t want to do. It is not saying, &#8220;you must enter all of the data we are asking you for or you may not enter!&#8221;</p>
<h3>Graphical Interface</h3>
<p><a href="http://lfoust.files.wordpress.com/2007/07/family.png" target="_blank"><img src="http://lfoust.files.wordpress.com/2007/07/family-thumb.png?w=240&#038;h=190" alt="family" width="240" height="190" align="left" /></a> Just the fact that Geni is a family tree application who&#8217;s main interface is actually a tree, makes it much more comfortable to use. Contrast this with another recent family tree application <a href="http://www.vertigo.com/familyshow.aspx" target="_blank">Family.Show</a> which displays the information in a tree, but you have to edit and view most information in a pane on the right side of the window.</p>
<h3>Collaboration Is Key</h3>
<p><img src="http://lfoust.files.wordpress.com/2007/07/treeinvite.png?w=204&#038;h=94" alt="treeinvite" width="204" height="94" align="left" /> The killer feature of Geni is the fact that it is family tree meets social networking. Anybody in your family can log on and add/edit information. This allows people to work on part of the tree that they are most familiar with. Also, there are other fun myspace like features like friends lists (people not in your family), picture sharing, and leaving messages. It is also extremely easy to invite somebody. Anytime you enter somebody&#8217;s email address, it allows you to invite them. This will send them an automated email inviting them to join Geni. While this feature is not totally new and innovative, it is usually a one click operation which makes you just that more likely to invite people.</p>
<h3>Don&#8217;t Underestimate the Power of Competition</h3>
<p><a href="http://lfoust.files.wordpress.com/2007/07/treeawards.png" target="_blank"><img src="http://lfoust.files.wordpress.com/2007/07/treeawards-thumb.png?w=240&#038;h=199" alt="treeawards" width="240" height="199" align="left" /></a> Do you have a little rivalry in your family? Geni allows you to use that competitive streak for good. The most obvious way it does this is by posting tree awards. Once my family members see this screen, they immediately want to be #1. This is such a great way to get people to participate. If they just add a couple of more people or upload some more pictures they can move up in the rankings. Not only is there competition between people in the same tree, I have found that there is a little game between me and friends to see who can get the most people in their tree. Just so you know, I think I am currently in the lead in this department.<img src="http://lfoust.files.wordpress.com/2007/07/treestats.png?w=240&#038;h=19" alt="treestats" width="240" height="19" /></p>
<p>I guess this also just proves my addiction since I have added the vast majority of the 207 people currently in my tree.</p>
<h3>Even my Grandma can use it</h3>
<p>Do you ever get tired of people using your mom or your grandma as the typical uninitiated computer user? Me too. I hear the phrase &#8220;This is so easy that my Grandma can use it!&#8221; Well, with Geni this is true from a UI perspective but I am talking about something better than than. Not only can Grandma use it, but she would really want to! Since family is such a unifying theme, having an application that taps into that is just brilliant. I have yet to have showed Geni to a family member who didn&#8217;t have an immediate interest.</p>
<h3>Is Your Application Addictive?</h3>
<p>The crazy thing about collaboration on the web today is that so many factors can contribute to the success or addictiveness of your application. It is not just a nice interface (see <a href="http://www.myspace.com" target="_blank">myspace</a>), and it is not just purely usefulness. Users have to connect with your application and feel welcomed. They don&#8217;t want to have to think too hard and to conform to the restrictions of the apps they are using.</p>
<p>I mainly worked on boring enterprise business applications, does this apply to me? Absolutely. Just because somebody is using an app on the intranet and they have no choice on whether or not to use your app or not, it does not mean you should not think about how to make their experience with that app the best it can possibly be. Can you make data entry or running reports fun? I think so.</p>
<p>What other addictive applications / user interfaces can you think of?</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/77/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/77/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/77/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=77&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/07/23/addictive-applications/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/07/treestart-thumb.png" medium="image">
			<media:title type="html">Easy to Start</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/07/family-thumb.png" medium="image">
			<media:title type="html">family</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/07/treeinvite.png" medium="image">
			<media:title type="html">treeinvite</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/07/treeawards-thumb.png" medium="image">
			<media:title type="html">treeawards</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/07/treestats.png" medium="image">
			<media:title type="html">treestats</media:title>
		</media:content>
	</item>
		<item>
		<title>Book Review: Smart And Get Things Done by Joel Spolsky</title>
		<link>http://lfoust.wordpress.com/2007/07/04/book-review-smart-and-get-things-done-by-joel-spolsky/</link>
		<comments>http://lfoust.wordpress.com/2007/07/04/book-review-smart-and-get-things-done-by-joel-spolsky/#comments</comments>
		<pubDate>Wed, 04 Jul 2007 18:45:25 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Book Review]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/07/04/book-review-smart-and-get-things-done-by-joel-spolsky/</guid>
		<description><![CDATA[I just recently finished the book Smart and Gets Things Done: Joel Spolsky&#8217;s Concise Guide to Finding the Best Technical Talent. Joel Spolsky is the author of the very popular blog Joel On Software and owner of Fog Creek Software. This is another one of those books that is very unique when it comes to [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=68&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.amazon.com/gp/product/1590598385?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=1590598385" target="_blank"><img style="margin:0 0 0 20px;" alt="smart" src="http://blog.spontaneouspublicity.com/files/2007/07/smart.jpg" align="right"></a></p>
<p><a href="http://www.amazon.com/gp/product/1590598385?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=1590598385" target="_blank"></a>I just recently finished the book <a href="http://www.amazon.com/gp/product/1590598385?ie=UTF8&amp;tag=spontanpublic-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590598385" target="_blank">Smart and Gets Things Done: Joel Spolsky&#8217;s Concise Guide to Finding the Best Technical Talent</a>. Joel Spolsky is the author of the very popular blog <a href="http://www.joelonsoftware.com/" target="_blank">Joel On Software</a> and owner of <a href="http://www.fogcreek.com/" target="_blank">Fog Creek Software</a>. This is another one of those books that is very unique when it comes to technical writing. It is both entertaining and informative. I don&#8217;t really think there is any other book like this out there. It is a fresh perspective on hiring technical talent written from the perspective of a developer who has been through the process of finding great talent.</p>
<p>The thesis of the book is that if you want to be successful in software, you have to hire the best developers and they will in turn develop the best software. The problem is, hiring the best developers is not an easy task as they never really tend to be looking for a job. The title comes from the basic description of what makes a great developer: Someone show is smart and gets things done.</p>
<p>Joel makes many assertions in this book that many companies don&#8217;t want to hear. Treat your software developers right. Buy them nice equipment. Give them private offices (gasp!). Apparently Joel practices what he preaches because nobody has ever quit their job from his company Fog Creak Software! That is amazing. That is the kind of company I want to work for.</p>
<p>Even if you are not a recruiter or heavily involved in hiring technical workers, this book still has plenty of value to you. If you are a developer, you can get a very good feeling for how good you are (are you smart and&nbsp;get things done?) and how to measure a company&#8217;s commitment to getting the best developers and making the best software.</p>
<p>There are a couple of points made in this book that I found very interesting and had never thought about before. First, the fact that the best developers are not really in it for the money &#8211; they just want to be taken care of by the company they work for. This is not really&nbsp;obvious to most companies who are hiring developers. Just look at how most startups try to attract talent.</p>
<p>The other interesting point was that what a company actually does makes a big difference to most developers. They want to work on something fun that they believe in. I wonder what effect this has on the quality of software that is not fun? How do you convince somebody to come write software for your cow manure processing plant?</p>
<p>This book is definitely worth the hour or two that it takes to read through it. Joel has a great writing style that is both engaging and informative.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/68/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/68/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/68/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=68&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/07/04/book-review-smart-and-get-things-done-by-joel-spolsky/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/07/smart.jpg" medium="image">
			<media:title type="html">smart</media:title>
		</media:content>
	</item>
		<item>
		<title>Book Review: Don&#8217;t Make Me Think by Steve Krug</title>
		<link>http://lfoust.wordpress.com/2007/07/03/book-review-dont-make-me-think-by-steve-krug/</link>
		<comments>http://lfoust.wordpress.com/2007/07/03/book-review-dont-make-me-think-by-steve-krug/#comments</comments>
		<pubDate>Tue, 03 Jul 2007 16:11:59 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Book Review]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/07/03/book-review-dont-make-me-think-by-steve-krug/</guid>
		<description><![CDATA[I know I am probably late to the game but I have just completed reading through Don&#8217;t Make Me Think by Steve Krug. I have recently become very interested in learning more about what I can do as a developer to improve the user experience of the apps I write. The thing is, I am [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=66&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a title="Don't Make Me Think" href="http://www.amazon.com/gp/product/0321344758?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0321344758" target="_blank"><img height="240" alt="Don't Make Me Think - Steve Krug" src="http://blog.spontaneouspublicity.com/files/2007/07/dontmakemethink.jpg" width="240" align="right"></a> </p>
<p>I know I am probably late to the game but I have just completed reading through <a href="http://www.amazon.com/gp/product/0321344758?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0321344758" target="_blank">Don&#8217;t Make Me Think</a> by <a href="http://www.sensible.com/" target="_blank">Steve Krug</a>. I have recently become very interested in learning more about what I can do as a developer to improve the user experience of the apps I write. The thing is, I am not and will never be much of a graphic designer or even a pro interaction designer. I do, however, think it is very important that I at least understand what it takes to be part of these disciplines.</p>
<h3>Practice What You Preach</h3>
<blockquote><p>I would have written a shorter letter, but I did not have the time.</p>
</blockquote>
<p>There are so many things that I loved about this book but the main one is the fact that it really tries to follow its own advice. It is a book about good design and making things simple and it does exactly that with a simple layout and clear narrative. This may seem like a small thing but it most definitely is not. Making things very clear and concise is much more difficult than just writing and rambling. This book was designed to be read in a single airplane ride so it is fairly light weight. But this does not mean that the content is not deep.</p>
<p>It sounds like writing the second edition of this book was an exercise in usability testing and paring down to the bare minimum. Mr. Krug took his readers suggestions and comments about the first edition and took them to heart. As a result, there were chapters that were taken out in the transition for the good of the book. This is really a remarkable move by the author. Usually authors are trying to add more and more content to their books to sell more copies. Don&#8217;t feel left out if you don&#8217;t buy the first edition because the missing chapters are <a href="http://www.sensible.com/secondedition/index.html" target="_blank">available online</a>.</p>
<h3>Worth Its Weight In Gold</h3>
<p>To me, the chapter on how to do usability testing for cheap is worth more than the price of the entire book. Krug spells out a very simple and clear way in which you can do usability testing on your own for about $600 or less. I have already brought this up in my company and received approval to go forward with some testing. I am really excited about getting real fresh input on some of our web sites.</p>
<h3>One thing I Didn&#8217;t Like</h3>
<p>I felt that the numerous footnotes in this book really distracted from the message of the book. I found myself constantly looking at the bottom of a page to read a footnote and losing my train of thought. Or, sometime I would reach the end of a page and see that there were footnotes on that page so I would go back and find the reference that I had missed. Again, this just distracted from the flow of the book. In many cases, the footnotes were just little jokes that could have been interjected into the text. I understand that the book is meant to be witty and easy to read, but many of the &#8220;jokes&#8221; just got in the way.</p>
<p>So go out now and <a href="http://www.amazon.com/gp/product/0321344758?ie=UTF8&amp;tag=spontanpublic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0321344758" target="_blank">buy this book</a>. And let me know what you think and how you plan to apply it to your work.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/66/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/66/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/66/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=66&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/07/03/book-review-dont-make-me-think-by-steve-krug/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/07/dontmakemethink.jpg" medium="image">
			<media:title type="html">Don&#039;t Make Me Think - Steve Krug</media:title>
		</media:content>
	</item>
		<item>
		<title>Southern California Code Camp In Review</title>
		<link>http://lfoust.wordpress.com/2007/07/02/southern-california-code-camp-in-review/</link>
		<comments>http://lfoust.wordpress.com/2007/07/02/southern-california-code-camp-in-review/#comments</comments>
		<pubDate>Mon, 02 Jul 2007 20:57:54 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/07/02/southern-california-code-camp-in-review/</guid>
		<description><![CDATA[This past weekend I attended the Southern California Code Camp and I had a great time. This is the second code camp I have attended and I am continually amazed at the quality of the sessions. For those of you who don&#8217;t know, code camps are completely free events where the sessions are all made [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=64&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This past weekend I attended the <a target="_blank" href="http://www.socalcodecamp.com/">Southern California Code Camp</a> and I had a great time. This is the second code camp I have attended and I am continually amazed at the quality of the sessions. For those of you who don&#8217;t know, code camps are completely free events where the sessions are all made of of community driven content (anybody can propose a session and potentially be a speaker). Sure there were some big name speakers such as <a target="_blank" href="http://www.dasblonde.net/">Michele Leroux Bustamante</a> and <a target="_blank" href="http://www.campbellassociates.ca/">Richard Campbell</a> (of <a target="_blank" href="http://www.dotnetrocks.com/">.Net Rocks</a> fame), but there were also tons of speakers who are just regular mortals like you and me&#8230;well me.</p>
<p>For me, this was a weekend of just trying new things and just hoping for the best. And I must say that it was a success. What do I mean by new things? Well, those of you who know me realize that I don&#8217;t usually put myself in social situations where I have to meet new people or make small talk on purpose. This means at the last code camp I attended, I just went to sessions and enjoyed the content &#8211; but I didn&#8217;t really bother to talk to anybody really. Well, this time I decided to try my hand at stepping out so I decided to volunteer to help out. This gave me opportunity to <a target="_blank" href="http://weblogs.asp.net/jgalloway/" title="Jon Galloway">meet</a> <a target="_blank" href="http://blog.pewitt.org/" title="Woddy Pewitt">tons</a> of <a target="_blank" href="http://geekswithblogs.net/bloesgen/Default.aspx" title="Brian Loesgen">cool</a> <a target="_blank" href="http://www.linkedin.com/pub/0/a33/9" title="Marie Watkins">people</a>.</p>
<p>Here is a list of my favorite sessions:</p>
<ul>
<li><a href="http://www.socalcodecamp.com/session.aspx?sid=32f65bf8-458b-4e28-8b7c-110d7efa639f">Ask a Recruiter</a> - Chuck Middendorf and Marie Watkins &#8211; This was just a casual time of question and answer. Chuck and Marie had very useful advice to share when it comes to resumes and recruiting.</li>
<li><a href="http://www.socalcodecamp.com/session.aspx?sid=2f388737-bcba-48af-8984-992dae31989b" title="Calling Web Services with ASP.NET AJAX">Calling Web Services with ASP.NET AJAX</a> - <a target="_blank" href="http://blogs.msdn.com/bags/">Rob Bagby</a> - You can really tell that Rob knows his stuff when it comes to asp.net ajax. I really like the new term he coined &#8211; Ajax Service. It captures perfectly that the fact that an .asmx file in Asp.Net ajax doesn&#8217;t have to speak soap, it defaults to the lighter weight JSON/Restful type service.</li>
<li><a href="http://www.socalcodecamp.com/session.aspx?sid=aa7cf8b6-49cb-4a4b-abfa-2b68aeb8ef0d" title="Building a Claims-Based Security Model with WCF">Building a Claims-Based Security Model with WCF</a> - <a href="http://www.dasblonde.net/"></a><a target="_blank" href="http://www.dasblonde.net/">Michele Leroux Bustamante</a> - I make sure I attend Michele&#8217;s talks when I can because they are guaranteed to be extremely informative and helpful.</li>
<li><a href="http://www.socalcodecamp.com/session.aspx?sid=ad66dd85-5ffc-4231-b3e6-c3a579d43de2" title="SQL Querying Tips &amp; Tricks">SQL Querying Tips &amp; Tricks</a> - <a target="_blank" href="http://www.campbellassociates.ca/">Richard Campbell</a> - This was my first time seeing Richard speak and I was really amazed at what a great speaker he is. You can just tell that Richard is extremely knowledgeable about so many topics that you can&#8217;t help be in awe.</li>
<li><a href="http://www.socalcodecamp.com/session.aspx?sid=0bf99110-6bf3-4ce8-94de-1998111bef73" title="The Scaling Habits of ASP.NET Applications">The Scaling Habits of ASP.NET Applications</a> - <a target="_blank" href="http://www.campbellassociates.ca/">Richard Campbell</a> - Again, an amazing session which I can immediately apply at my job.</li>
</ul>
<p>My personal goal is to be a presenter at next years code camp. Now I just have to find a topic and the right T shirt to wear.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/64/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/64/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/64/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=64&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/07/02/southern-california-code-camp-in-review/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Windows Vista: A prisoner in my own computer</title>
		<link>http://lfoust.wordpress.com/2007/06/28/windows-vista-a-prisoner-in-my-own-computer/</link>
		<comments>http://lfoust.wordpress.com/2007/06/28/windows-vista-a-prisoner-in-my-own-computer/#comments</comments>
		<pubDate>Thu, 28 Jun 2007 17:25:36 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/06/28/windows-vista-a-prisoner-in-my-own-computer/</guid>
		<description><![CDATA[Well, I have had Windows Vista installed on my development machine for about 5 months now and feel it is time to reflect on my experience. As you may infer from my post title, there are many things I don&#8217;t like. There are, however, many things that I do like so I will start with [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=63&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Well, I have had Windows Vista installed on my development machine for about 5 months now and feel it is time to reflect on my experience. As you may infer from my post title, there are many things I don&#8217;t like. There are, however, many things that I do like so I will start with those.</p>
<h3>User Interface Enhancements</h3>
<p>I am not going to gush about all the cool little &#8220;flashy&#8221; things that were added to the Vista UI. In fact, I find most of them pretty useless. But there are a couple of small things which I really like and find that they add value. An obvious one is the ability to search the start menu. I love being able to open up programs <a title="Mouseless Computing" href="http://weblogs.asp.net/jgalloway/archive/2006/06/14/Mouseless-Computing.aspx" target="_blank">without having to ever use my mouse</a>. I do not, however, include the entire searching feature that is built into Vista in my list of good features. In fact, the search seems to be pretty much useless every time I use it so I am slowly learning to avoid it.</p>
<p>I also really like how the file path displayed at the top of Windows Explorer can be used as a clickable bread crumb for navigation. I use this feature all of the time.</p>
<p>The last small UI enhancement that I find a lot of value in is the new menu that pops up when you use Alt+Tab. I was a big fan of <a href="http://www.ntwind.com/software/taskswitchxp.html" target="_blank">TaskSwitchXp</a> as a replacement for the Alt+Tab menu in Xp and I find it even better when useful features like this are just built into the operating system.</p>
<h3>IIS7 &#8211; Finally Multiple Web Sites</h3>
<p>As a web developer using Windows XP, I found it very limiting to be able to only have one web site under IIS. I know that there were <a href="http://weblogs.asp.net/stevencohn/articles/59782.aspx" target="_blank">ways around this limitation</a>, but I found them to be very cumbersome. So then I moved to Windows Server 2003 as my development machines OS, but this always felt like a step backwards. I was giving up many things I liked in XP just to have multiple web site. Well, this problem is fixed with the inclusion of <a href="http://www.iis.net/" target="_blank">IIS7</a> in Windows Vista. Multiple web sites is not the only feature I love about IIS7 &#8211; I also love the new management interface and the integration with .Net.</p>
<p>I am sure there are other small things that I have grown used to in Vista that I just can&#8217;t recall, but I think I have covered the major ones (kind of small list huh?)</p>
<h3>Do I Feel More Secure?</h3>
<p>I know there is <a href="http://www.codinghorror.com/blog/archives/000891.html" target="_blank">a lot of discussion</a> about how users (even developers) should never run as Administrator just to do every day tasks. I even agree with a lot of the arguments. Developers running as administrators just seems to propagate the problem because they develop software which requires admin access. So am I just a lazy developer who doesn&#8217;t want to go through the trouble of dealing with less than administrator access? I don&#8217;t think I am.</p>
<p>Rather than tackle this whole subject at once, I think I will just focus on my development experience using Visual Studio 2005 to develop web applications on Vista. So you want to access we web site in a Visual Studio project via IIS? Well then you better remember to right click on the visual studio short cut when you launch it and choose &#8216;Run as Administrator&#8217;. Otherwise, you get this:<img height="129" alt="VS-no website" src="http://blog.spontaneouspublicity.com/files/2007/06/vs-no-website.png" width="341"> </p>
<p>So I guess if I want to work with websites I have to remember to always remember to run VS as administrator? This is just one more thing to make my life harder.</p>
<p>Here is another problem I run into all of the time -&nbsp;Drag and drop. For some reason, somebody decided that it would not be secure to drag something from a program that is not running as administrator to one that is. So I remember to open visual studio as Administrator so I can work with web sites but then I want to drag some files onto it to open them, I get this:<a href="http://blog.spontaneouspublicity.com/files/2007/06/vs-no-drag.png"><img height="196" alt="VS-no drag" src="http://blog.spontaneouspublicity.com/files/2007/06/vs-no-drag-thumb.png" width="290"></a> </p>
<p>I can&#8217;t even take a bunch of items and drag them onto solution explorer to add them to my project. I have to use the &#8220;Add existing item&#8221; dialog to add each folder of items separately. So basically I have sacrificed usability for security. But is it more secure? How was dragging and dropping a security hazard for me in the past? It wasn&#8217;t.</p>
<p>I was going to include a discussion about problems I have debugging web sites using visual studio due to even more security constraints, but then I noticed that <a href="http://weblogs.asp.net/scottgu/" target="_blank">Scott Guthrie</a> <a href="http://weblogs.asp.net/scottgu/archive/2007/06/27/public-hotfix-patch-available-for-debugging-asp-net-on-iis7.aspx" target="_blank">announced</a> a <a href="http://connect.microsoft.com/VisualStudio/Downloads/DownloadDetails.aspx?DownloadID=7250" target="_blank">hot fix for this problem</a>. Hopefully this fixes my problem</p>
<h3>Can I please Move Files?</h3>
<p>There is one last usability thing that I want to discuss &#8211; the process of moving or copying files. I know many people have already <a href="http://www.theregister.co.uk/2007/03/26/vista_copying_bug/" target="_blank">expressed outrage</a> about the speed of copying and moving files. I have more of a problem with the dialog boxes used in copying. <a href="http://www.hanselman.com/blog/" target="_blank">Scott Hanselman</a> has <a href="http://www.hanselman.com/blog/TMIToMuchInformationNetworkingDialogBoxOfTheDay.aspx" target="_blank">expressed grief about the Network Diagnostics dialog box</a>. My problems with the move files dialogs are very much the same. <a href="http://www.shahine.com/omar/default.aspx" target="_blank">Omar Shahine</a> has also <a href="http://www.shahine.com/omar/MostAnnoyingVistaFeatureReplaceConfirmations.aspx" target="_blank">talked about the file dialogs</a> in the past. So here is the scenario &#8211; I want to take a bunch of files and folders and move them over to a server while replacing what is there. In Xp, this was just a matter of doing a copy and paste (or a drag drop) and then clicking a &#8220;Yes to All&#8221; button when you were prompted to replace. In Vista you get two different dialog boxes. First one for folders:<img height="480" alt="replace folder dialog" src="http://blog.spontaneouspublicity.com/files/2007/06/replace-folder-dialog.png" width="465"></p>
<p>So since I want to replace everything, I have to click the checkbox at the bottom and then click&nbsp;&#8217;Yes&#8217;. But then I am prompted with another dialog for files:<img height="480" alt="replace file dialog" src="http://blog.spontaneouspublicity.com/files/2007/06/replace-file-dialog.png" width="467"> &nbsp; </p>
<p>Now I have to again, click the checkbox at the bottom, but now the UI is different from the last dialog. Instead of clicking yes, I must choose one of the three huge button choices: &#8220;Move and replace&#8221;, &#8220;Don&#8217;t Move&#8221;, or &#8220;Move, but keep both files&#8221;. This confuses my brain because it is different than the last dialog. And why does there have to be two separate dialogs? Can&#8217;t they just warn me once?</p>
<p>I also like <a href="http://miksovsky.blogs.com/about.html" target="_blank">Jan Miksovsky&#8217;s</a><strong> </strong><a href="http://miksovsky.blogs.com/flowstate/2007/06/dont-bury-the-l.html" target="_blank">thoughts on the replace file dialog</a>.</p>
<h3>Just let me do what I want</h3>
<p>So my overall feeling as a developer using vista is I am trapped. I have to walk around with shackles. Am I just a walking security hazard? I think that if the powers that be want me to be running as a regular user, the tools need to support it much better than they do. <a href="http://en.wikipedia.org/wiki/User_Account_Control" target="_blank">UAC</a> is not the answer. More warnings and dialogs is never the answer. More restrictions do not really improve security in my opinion &#8211; it just alienates users.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/63/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/63/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/63/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/63/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/63/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=63&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/06/28/windows-vista-a-prisoner-in-my-own-computer/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/06/vs-no-website.png" medium="image">
			<media:title type="html">VS-no website</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/06/vs-no-drag-thumb.png" medium="image">
			<media:title type="html">VS-no drag</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/06/replace-folder-dialog.png" medium="image">
			<media:title type="html">replace folder dialog</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/06/replace-file-dialog.png" medium="image">
			<media:title type="html">replace file dialog</media:title>
		</media:content>
	</item>
		<item>
		<title>Is Hand Written Xml Too Much For Mere Mortals?</title>
		<link>http://lfoust.wordpress.com/2007/06/21/is-hand-written-xml-too-much-for-mere-mortals/</link>
		<comments>http://lfoust.wordpress.com/2007/06/21/is-hand-written-xml-too-much-for-mere-mortals/#comments</comments>
		<pubDate>Fri, 22 Jun 2007 02:34:23 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/06/21/is-hand-written-xml-too-much-for-mere-mortals/</guid>
		<description><![CDATA[I am currently working on a project that requires the editing of information in a very free flowing way (like in Word or Excel) but has very strict data and validation conditions as well. I have considered many different mechanisms/interfaces which would allow a reasonable amount of freedom on the users part but still be [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=57&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I am currently working on a project that requires the editing of information in a very free flowing way (like in Word or Excel) but has very strict data and validation conditions as well. I have considered many different mechanisms/interfaces which would allow a reasonable amount of freedom on the users part but still be able to adhere to a formal structure.</p>
<p>The solution that I am currently considering is to have the users just edit Xml directly. The users in this case are very capable and can adapt pretty well to new ideas. Here are is my current list of pros and cons:</p>
<h3>Pros</h3>
<ul>
<li>Easily Validated</li>
<li>Fairly easy to read, understand and write</li>
<li>Possible intellisense with the right editor</li>
<li>Easy to program against</li>
<li>Lends itself well to heirarichal data</li>
</ul>
<h3>Cons</h3>
<ul>
<li>Very verbose</li>
<li>Another language for users to learn</li>
<li>No consumer level editor</li>
</ul>
<p>So with the above lists, Xml is not looking like too bad of a choice. Did I miss any pros or cons?</p>
<p>I have also been looking for a good Xml editor that the people can use to author the documents with. My first idea was the <a href="http://www.microsoft.com/downloads/details.aspx?familyid=72d6aa49-787d-4118-ba5f-4f30fe913628&amp;displaylang=en">Microsoft Xml Notepad</a>. Maybe I am missing something but that tool seems very awkward and hard to use, not to mention the fact that you have to edit an xml file as if it were a tree. Then, I thought of <a href="http://www.sharpdevelop.com/OpenSource/SD/Default.aspx">SharpDevelop </a>- a free, open source, .Net IDE that has a pretty decent Xml editor (I still think visual studio 2005 is the best I have used). I downloaded it and tried out SharpDevelop and it seems to work very well. It would fit the bill for this project because it is free and lightweight.</p>
<p>So what do you think &#8211; Is hand writing Xml too much to ask of the average user?</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/57/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/57/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/57/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/57/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/57/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/57/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/57/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/57/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/57/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/57/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=57&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/06/21/is-hand-written-xml-too-much-for-mere-mortals/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Yui.Net: The Tooltip</title>
		<link>http://lfoust.wordpress.com/2007/06/20/yuinet-the-tooltip/</link>
		<comments>http://lfoust.wordpress.com/2007/06/20/yuinet-the-tooltip/#comments</comments>
		<pubDate>Wed, 20 Jun 2007 22:40:15 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[YUI.Net]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/06/20/yuinet-the-tooltip/</guid>
		<description><![CDATA[As part of my ongoing series covering the Yui.Net library (an asp.net wrapper for the Yahoo User Interface Library), today I will cover a fairly simple but useful component &#8211; the ToolTip. This component is exactly what you would expect it to be &#8211; a ToolTip which you can associate with any element on the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=56&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://blog.spontaneouspublicity.com/files/2007/06/tooltip.png"><img style="border-right:0;border-top:0;border-left:0;border-bottom:0;" height="72" alt="Tooltip" src="http://blog.spontaneouspublicity.com/files/2007/06/tooltip-thumb.png" width="240" border="0"></a>
<p>As part of my ongoing series covering the <a href="http://www.codeplex.com/YuiDotNet" target="_blank">Yui.Net library</a> (an asp.net wrapper for the <a href="http://developer.yahoo.com/yui/" target="_blank">Yahoo User Interface Library</a>), today I will cover a fairly simple but useful component &#8211; the <a href="http://developer.yahoo.com/yui/container/tooltip/" target="_blank">ToolTip</a>. This component is exactly what you would expect it to be &#8211; a ToolTip which you can associate with any element on the page. The nice thing about the YUI ToolTip is that it can contain html code, can be styled via css and it can have <a href="http://developer.yahoo.com/yui/animation/" target="_blank">animations</a> applied to it.</p>
<p>Lets start with a simple&nbsp;example &#8211; a div with a basic tool tip. As with all Yui.Net controls, you must first include the YahooScriptManager on your page:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">yui</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">YahooScriptManager</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="manager"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>Next, we&#8217;ll just place a simple div:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">div</span> <span style="color:rgb(255,0,0);">id</span><span style="color:rgb(0,0,255);">="content"&gt;</span>Just a simple div<span style="color:rgb(0,0,255);">&lt;/</span><span style="color:rgb(163,21,21);">div</span><span style="color:rgb(0,0,255);">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>then we can place our ToolTip control on the page:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">yui</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">Tooltip</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="toolTip"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(255,0,0);">ContextID</span><span style="color:rgb(0,0,255);">="content"</span> <span style="color:rgb(255,0,0);">Text</span><span style="color:rgb(0,0,255);">="This is a simple tooltip!"</span> <span style="color:rgb(0,0,255);">/&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>this will cause a simle tooltip popup when you place your mouse over the div. Lets take a look at the code that is generated by these controls. First, there are the necessary script tags managed by the YahooScriptManager:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">script</span> <span style="color:rgb(255,0,0);">src</span><span style="color:rgb(0,0,255);">="http://yui.yahooapis.com/2.2.2/build/yahoo-dom-event/yahoo-dom-event.js"</span> <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text/javascript"&gt;&lt;/</span><span style="color:rgb(163,21,21);">script</span><span style="color:rgb(0,0,255);">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>then there is the javascript initialization of the tooltip object:</p>
<pre><span style="color:rgb(0,0,255);">var</span> toolTip = <span style="color:rgb(0,0,255);">new</span>  YAHOO.widget.Tooltip(<span style="color:rgb(163,21,21);">"toolTip"</span>, {
    visible: <span style="color:rgb(0,0,255);">false</span>, constraintoviewport: <span style="color:rgb(0,0,255);">true</span>, iframe : <span style="color:rgb(0,0,255);">false</span>,
    context: <span style="color:rgb(163,21,21);">"content"</span>, text: <span style="color:rgb(163,21,21);">"This is a simple tooltip!"</span>} );</pre>
<p>That is all that is really needed for a basic tooltip. Now, lets add a fade animation so that the ToolTip will fade in an out nicely:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">yui</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">Tooltip</span> <span style="color:rgb(255,0,0);">ID</span><span style="color:rgb(0,0,255);">="toolTip"</span> <span style="color:rgb(255,0,0);">runat</span><span style="color:rgb(0,0,255);">="server"</span> <span style="color:rgb(255,0,0);">ContextID</span><span style="color:rgb(0,0,255);">="content"</span> <span style="color:rgb(255,0,0);">Text</span><span style="color:rgb(0,0,255);">="This is a simple tooltip!"&gt;
</span>    <span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">Animations</span><span style="color:rgb(0,0,255);">&gt;
</span>        <span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">yui</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">Animation</span> <span style="color:rgb(255,0,0);">Type</span><span style="color:rgb(0,0,255);">="Fade"</span> <span style="color:rgb(255,0,0);">Duration</span><span style="color:rgb(0,0,255);">="3"</span> <span style="color:rgb(0,0,255);">/&gt;
</span>    <span style="color:rgb(0,0,255);">&lt;/</span><span style="color:rgb(163,21,21);">Animations</span><span style="color:rgb(0,0,255);">&gt;
&lt;/</span><span style="color:rgb(163,21,21);">yui</span><span style="color:rgb(0,0,255);">:</span><span style="color:rgb(163,21,21);">Tooltip</span><span style="color:rgb(0,0,255);">&gt;</span></pre>
<p>This will cause an extra script reference to be generated by the YahooScriptManager:</p>
<pre><span style="color:rgb(0,0,255);">&lt;</span><span style="color:rgb(163,21,21);">script</span> <span style="color:rgb(255,0,0);">src</span><span style="color:rgb(0,0,255);">="http://yui.yahooapis.com/2.2.2/build/animation/animation-min.js"</span> <span style="color:rgb(255,0,0);">type</span><span style="color:rgb(0,0,255);">="text/javascript"&gt;&lt;/</span><span style="color:rgb(163,21,21);">script</span><span style="color:rgb(0,0,255);">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>Whenever possible the YahooScriptManager will only include the references needed for the needed functionality so the animation library is only included if a control on the current page will need animation. Actually, it is not the YahooScriptManager that makes this decision but it is the controls themselves. Now the generated javascript looks like:</p>
<pre><span style="color:rgb(0,0,255);">var</span> toolTip = <span style="color:rgb(0,0,255);">new</span>  YAHOO.widget.Tooltip(<span style="color:rgb(163,21,21);">"toolTip"</span>,
    { visible: <span style="color:rgb(0,0,255);">false</span>, effect:
    {effect:YAHOO.widget.ContainerEffect.FADE,duration:0.3},
    constraintoviewport: <span style="color:rgb(0,0,255);">true</span>, iframe : <span style="color:rgb(0,0,255);">false</span>, context: <span style="color:rgb(163,21,21);">"content"</span>,
    text: <span style="color:rgb(163,21,21);">"This is a simple tooltip!"</span>} );</pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>That is about all you really need to know about the ToolTip control to get started. Pretty standard really. Next up I will cover the FloatPanel control and some new features I am building into the YUI.Net library for dealing with javascript events.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/56/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/56/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/56/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/56/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/56/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=56&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/06/20/yuinet-the-tooltip/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://blog.spontaneouspublicity.com/files/2007/06/tooltip-thumb.png" medium="image">
			<media:title type="html">Tooltip</media:title>
		</media:content>
	</item>
		<item>
		<title>My Learning Todo List</title>
		<link>http://lfoust.wordpress.com/2007/06/18/my-learning-todo-list/</link>
		<comments>http://lfoust.wordpress.com/2007/06/18/my-learning-todo-list/#comments</comments>
		<pubDate>Mon, 18 Jun 2007 19:23:10 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.spontaneouspublicity.com/2007/06/18/my-learning-todo-list/</guid>
		<description><![CDATA[Asp.Net Alternative All of this talk about Asp.Net being a leaky abstraction and having an overly complicated page lifecycle, I have been considering looking at some alternatives to see what all the fuss is about. I am one of those developers who has taken the time to learn a lot about the page lifecycle and [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=53&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h3>Asp.Net Alternative</h3>
<p>All of <a href="http://bugthis.blogspot.com/2007/03/why-aspnet-is-leaky-example-of-over.html" target="_blank">this talk</a> about <a href="http://www.ayende.com/Blog/archive/2007/03/05/Removing-the-leaky-abstractions-from-WebForms.aspx" target="_blank">Asp.Net being a leaky abstraction</a> and having an <a href="http://www.ayende.com/Blog/archive/2006/10/26/7147.aspx" target="_blank">overly complicated page lifecycle</a>, I have been considering looking at some alternatives to see what all the fuss is about. I am one of those developers who has taken the time to learn a lot about the page lifecycle and am fairly comfortable with it. I don&#8217;t think this means that I should get too comfortable. I have to agree that the current model doesn&#8217;t really promote good design and separation of concerns like it should. So here is my &#8220;alternative to Asp.net&#8221; list:</p>
<ul>
<li><a href="http://www.castleproject.org/monorail/index.html" target="_blank">MonoRail</a></li>
<li><a href="http://structuremap.sourceforge.net/Default.htm" target="_blank">StructureMap</a></li>
<li><a href="http://www.castleproject.org/activerecord/index.html" target="_blank">ActiveRecord</a></li>
<li><a href="http://www.hibernate.org/343.html" target="_blank">NHibernate</a> (I know this doesn&#8217;t really have to go along with the above)</li>
</ul>
<h3>Language Of The Year</h3>
<p>I am also very interested in the trend to <a href="http://www.pragmaticprogrammer.com/loty/" target="_blank">learn a new programming language every year</a>. <a href="http://www.hanselman.com/blog/ProgrammerIntentOrWhatYoureNotGettingAboutRubyAndWhyItsTheTits.aspx" target="_blank">Many people</a> have decided to choose one of the new cool languages like <a href="http://www.ruby-lang.org/en/" target="_blank">Ruby</a> or <a href="http://boo.codehaus.org/" target="_blank">Boo</a>.&nbsp; I was considering following suite until I watched <a href="http://video.yahoo.com/video/play?vid=630959" target="_blank">this video</a> over at <a href="http://developer.yahoo.com/yui/theater/" target="_blank">YUI Theater</a>. I realized that I have been using javascript on and off for over 8 years and I have never really stopped to learn it. So I have decided to make javascript my language for the year. Like many server side, compiled language programmers, I have never like javascript. Now that the <a href="http://www.aptana.com/" target="_blank">tools</a> for developing and <a href="http://www.getfirebug.com/" target="_blank">debugging</a>&nbsp;in javascript are improving I have decided to give it a fair shake. <a href="http://weblogs.asp.net/scottgu/archive/2007/04/24/javascript-intellisense-in-visual-studio-orcas.aspx" target="_blank">Visual Studio 2008 will even have intellisense for javascript</a>! (how did this feature take this long to come about?) I think I will start my javascript journey by focusing in on javascript librarires &#8211; starting with <a href="http://ajax.asp.net/" target="_blank">Asp.Net Ajax</a> and the&nbsp;<a href="http://developer.yahoo.com/yui/" target="_blank">Yahoo User Interface Library</a>.</p>
<h3>.Net 3.5</h3>
<p>Lastly, there are is the huge learning opportunity that is .Net 3.5 which will become more mainstream with the release of Visual Studio 2008. I have already ready a couple of books on <a href="http://wpf.netfx3.com/" target="_blank">WPF</a> and <a href="http://wcf.netfx3.com/" target="_blank">WCF</a> but I also want to add:</p>
<ul>
<li><a href="http://msdn2.microsoft.com/en-us/netframework/aa904594.aspx" target="_blank">Linq</a></li>
<li><a href="http://wf.netfx3.com/" target="_blank">Workflow</a></li>
<li><a href="http://cardspace.netfx3.com/" target="_blank">Cardspace</a></li>
<li><a href="http://silverlight.net/" target="_blank">Silverlight</a></li>
</ul>
<p>That should keep me busy for a while. The hard part for me is not so much in the learning but in finding ways which I can apply new things to my work while still fitting in with the applications/frameworks we currently have deployed.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/53/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/53/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/53/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/53/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/53/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=53&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/06/18/my-learning-todo-list/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Codesmith 4.0 Feedback and Feature Requests</title>
		<link>http://lfoust.wordpress.com/2007/06/05/codesmith-40-feedback-and-feature-requests/</link>
		<comments>http://lfoust.wordpress.com/2007/06/05/codesmith-40-feedback-and-feature-requests/#comments</comments>
		<pubDate>Tue, 05 Jun 2007 19:10:42 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/06/05/codesmith-40-feedback-and-feature-requests/</guid>
		<description><![CDATA[Codesmith is a product that I have considered purchasing multiple times in the past. It seems to be the code generations suite that has the best community built around it and I think that is a very import aspect of any software I purchase. Every time I download the trial of Codesmith, my trial expires [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=49&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a target="_blank" href="http://www.codesmithtools.com/">Codesmith</a> is a product that I have considered purchasing multiple times in the past. It seems to be the code generations suite that has the <a target="_blank" href="http://community.codesmithtools.com/">best community built around it</a> and I think that is a very import aspect of any software I purchase. Every time I download the trial of Codesmith, my trial expires before I find a compelling reason to purchase the product.</p>
<p>Well, the other day I received a free licence for Codesmith 4.0 professional so I decided to use it on a project I am working on. After spending a couple of days with the product there are many features which I feel are missing or need some improvement. Some of them seem so glaring that I plan on following up with support to make sure I understand the functionality and the documentation correctly. It is also possible that the scenarios that Codesmith is meant to target are just not what I am trying to use it for. It seems that Codesmith is very well suited for walking through database structures and generating stored procedures or some sort of custom data layer, but that is not really what I want to use it for.</p>
<h3>Background</h3>
<p>First I want to explain what I am attempting to use code generation for. Basically, I am generating an asp.net website based on configuration in a database. I already have a separate app that is used to input the configuration parameters and now I am trying to use Codesmith templates to generate the website. So here is the basic structure of my project:</p>
<p>I have created a base class for all the templates which includes some properties and functionality that will be common to all the code templates in this project. I created this class in Visual Studio and so it is in a re-usable dll. I also have other classes in this assembly which are used to hold common configuration parameters and such.</p>
<p>I plan on making three template files (.cst) for each aspx page I am generating. One for the code behind(.cs), one for the markup (.aspx), and one &#8220;master&#8221; template that will call the other two templates.</p>
<p>In the end, I will be writing my own client which will use the Codesmith API to run the templates and generate the website.</p>
<h3>Visual Studio Integration</h3>
<p>With <a target="_blank" href="http://www.codesmithtools.com/usersguide/Visual_Studio_Integration.html">visual studio integration</a> being a feature, I assumed that this would allow you to view, edit, and run your code templates inside of Visual Studio. I was expecting an experience where I can open Visual Studio, choose &#8220;New Codesmith Project&#8221; or &#8220;Add Codesmith template&#8221; to an existing project and then begin editing both the .cst file as well as the .cs code behind file. Well, the only visual studio template that is provided is a &#8220;Add Codesmith project&#8221; which simply adds a Codesmith project (.csp) to your project. This features helps you manage code generation as part of your build process. And when it comes to editing and running your code templates, they still open up in Codesmith Studio which is external to Visual Studio. This wouldn&#8217;t be so bad except the development experience in Codesmith Studio is nowhere near as nice as Visual Studio. The intellisense only seems to work part of the time, the code formatting is not very configurable, and it just feels a lot more like editing in notepad than it does a development IDE.</p>
<p>Reading through the <a target="_blank" href="http://community.codesmithtools.com/forums/5/ShowForum.aspx">feature request</a> at the <a target="_blank" href="http://community.codesmithtools.com/forums/default.aspx">Codesmith forums</a> lead me to believe that <a target="_blank" href="http://community.codesmithtools.com/forums/thread/23877.aspx">I am not alone</a> in my frustrations with the Visual Studio integration. I have seen other products do a much better job of leveraging the fact that I am comfortable and much more productive in Visual Studio. Codesmith Studio should only be for developers who do not have Visual Studio.</p>
<h3>Assembly References</h3>
<p>As I mentioned earlier, I want to use a common assembly to hold some base and utility classes for my templates. There is one problem though, if you want to use any external assemblies, they must be in one of three places:</p>
<ul>
<li>The GAC</li>
<li>The Visual Studio PublicAssemblies Folder</li>
<li>The Codesmith Addins folder</li>
</ul>
<p>So this basically means that I have to finish developing my external assemblies BEFORE I begin developing my code templates or I can just copy my assembly manually over to one of the folders above every time I make a new build of it. Well, that may not be so bad except for the fact that the Codesmith Studio holds on to the assembly once you use it in a template so I can&#8217;t replace it in the file system until I completely close Codesmith Studio. This is annoying to say the least.</p>
<p>I do not know how the Codesmith engine works under the hood, but I assume it is doing some sort of build which results in a .Net assembly or something very similar. I think it would be ideal if you could just have a Codesmith visual studio project type which would result in an assembly which could be referenced in other visual studio projects. This would really open up tons of new scenarios for sharing templates across applications as well as with the community. Having the templates in a assembly package would also make using the <a target="_blank" href="http://www.codesmithtools.com/usersguide/Programatically_Executing_Templates.html">Codesmith API</a> much easier. Instead of having to point the CodeTemplateCompiler to a .cst file, I would like to be able pass it an instance of a CodeTemplate class which it can then operate on.</p>
<h3>Code Behind</h3>
<p>I realize intellisense is probably a very hard feature to implement but whenever I use a product has it implemented but it only works sometimes, this almost makes me wish it weren&#8217;t there at all. If you can&#8217;t count on a feature, then it is more of an annoyance than a help. The code behind model seems like it is something that was just tacked on to Codesmith and is not really supported all that well. For starters, I can&#8217;t figure out how to add a .cs code behind file to the Codesmith Explorer window. If I right click, there is not &#8220;new C# file&#8221; option and if I try to rename another file to a .cs extension it complains that it is not a valid extension. The only way I have been able to add my own code behind files into the Codesmith explorer is to create a blank cs file and move it into the same folder as my template using windows explorer. Then it shows up in the Codesmith explorer. Maybe my experience as an Asp.Net developer pushes me towards the code behind model because it seems that Codesmith templates are more geared towards the inline classic asp type model of coding.</p>
<h3>Conclusion</h3>
<p>I hope all of this ranting makes you think I hate Codesmith. On the contrary, I think it is a pretty cool product that has a very wide variety of applications. I guess I am just spoiled by Visual Studio. I am a big believer that when you create tools for a development platform like .Net or Visual Studio, you should make things work just like they were always part of the platform. For example, if you are writing APIs, they should conform as closely as possible to the BCL standards as far as naming etc. Codesmith essentially introduces a new file type into my development arsenal: the .cst template file. Having to use these files outside of Visual studio when I am trying to integrate them with a project that is being developed inside of the Visual Studio IDE just feels wrong. I would love to hear from the Codesmith team as to what their plans are beyond version 4.0</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/49/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/49/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/49/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/49/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/49/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/49/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/49/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/49/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/49/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/49/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=49&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/06/05/codesmith-40-feedback-and-feature-requests/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Child Collections in Asp.Net Custom Controls</title>
		<link>http://lfoust.wordpress.com/2007/05/23/child-collections-in-aspnet-custom-controls/</link>
		<comments>http://lfoust.wordpress.com/2007/05/23/child-collections-in-aspnet-custom-controls/#comments</comments>
		<pubDate>Wed, 23 May 2007 17:47:04 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/05/23/child-collections-in-aspnet-custom-controls/</guid>
		<description><![CDATA[I have been developing custom web controls for many years now and I am just now getting comfortable with many of the advanced features afforded by the rich System.Web.UI.WebControls namespace. One feature I have implemented many different times over the years is having a web control which contains a list of sub items. For example, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=48&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have been developing custom web controls for many years now and I am just now getting comfortable with many of the advanced features afforded by the rich System.Web.UI.WebControls namespace. One feature I have implemented many different times over the years is having a web control which contains a list of sub items. For example, the Asp.Net GridView&#8217;s collection of Columns or the DropDownList&#8217;s collection of ListItems.    </p>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">asp</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">GridView</span> <span style="color:#ff0000;">ID</span><span style="color:#0000ff;">=&quot;grid&quot;</span> <span style="color:#ff0000;">runat</span><span style="color:#0000ff;">=&quot;server&quot;&gt;
</span>    <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">Columns</span><span style="color:#0000ff;">&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">asp</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">BoundField</span> <span style="color:#0000ff;">/&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">asp</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">ButtonField</span> <span style="color:#0000ff;">/&gt;
</span>    <span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">Columns</span><span style="color:#0000ff;">&gt;
&lt;/</span><span style="color:#a31515;">asp</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">GridView</span><span style="color:#0000ff;">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p><a href="http://11011.net/software/vspaste"></a>There is so many things going on it a control like this that just seem like magic. How are the child items persisted in ViewState? How does the control know how to parse the child items? What if the whole world were a power ranger?</p>
<h3>StateManagedItem</h3>
<p>I have created a couple of classes that really simplify the process of creating lists of child items. The first of which is the class <span style="color:#2b91af;">StateManagedItem</span>. This class is the base class for all the objects which you wish to use as &quot;Child Items&quot; (like grid view columns or list items).</p>
<p>In order to manage state in Asp.Net, you have to implement the <span style="color:#2b91af;">IStateManager </span>interface. This interface allows objects to participate in the process of saving and retrieving things from ViewState. In order to generalize the whole process, I needed on other method to set an item as &quot;Dirty&quot; so I created the following interface:</p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">interface</span> <span style="color:#2b91af;">IStateManagedItem</span> : <span style="color:#2b91af;">IStateManager
</span>{
    <span style="color:#0000ff;">void</span> SetDirty();
}</pre>
<p>
  <br />So now we have the base interface for all state managed items. So here is the what the base class definition looks like: </p>
<p></p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">abstract</span> <span style="color:#0000ff;">class</span> <span style="color:#2b91af;">StateManagedItem</span> : <span style="color:#2b91af;">IStateManagedItem</span></pre>
<p><a href="http://lfoust.files.wordpress.com/2007/05/windowslivewriterchildcollectionsinasp.netcustomcontrols-94feimage03.png"><img height="240" src="http://lfoust.files.wordpress.com/2007/05/windowslivewriterchildcollectionsinasp.netcustomcontrols-94feimage0-thumb1.png?w=190&#038;h=240" width="190" /></a></p>
<p>This class provides it&#8217;s own ViewState for items to save their state in which essentially allows &quot;Child Items&quot; to save their state just like custom web controls do. To illustrate this concept, lets create an example class called Appointment which will hold information about a calendar appointment.</p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">class</span> <span style="color:#2b91af;">Appointment</span> : <span style="color:#2b91af;">StateManagedItem</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p><a href="http://lfoust.files.wordpress.com/2007/05/windowslivewriterchildcollectionsinasp.netcustomcontrols-94feimage07.png"><img height="190" src="http://lfoust.files.wordpress.com/2007/05/windowslivewriterchildcollectionsinasp.netcustomcontrols-94feimage0-thumb3.png?w=178&#038;h=190" width="178" /></a></p>
<p>The definition for this class is very simple. Here is how the properties are implemented:</p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#2b91af;">DateTime</span>? Start
{
    <span style="color:#0000ff;">get
</span>    {
        <span style="color:#0000ff;">object</span> o = ViewState[<span style="color:#a31515;">&quot;Start&quot;</span>];
        <span style="color:#0000ff;">return</span> o == <span style="color:#0000ff;">null</span> ? <span style="color:#0000ff;">null</span> : (<span style="color:#2b91af;">DateTime</span>?)o;
    }
    <span style="color:#0000ff;">set</span> { ViewState[<span style="color:#a31515;">&quot;Start&quot;</span>] = <span style="color:#0000ff;">value</span>; }
}</pre>
<p>If you are familiar with using ViewState to store web control properties, this syntax should look fairly familiar. That that is all there is to our child item.</p>
<h3>StateManagedCollection</h3>
<p>The next helper class is a base class for the collection of items. In our example, we need a collection of Appointments. For this purpose, I have created a StateManagedCollection&lt;T&gt; class which can be used to hold the child items.</p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">abstract</span> <span style="color:#0000ff;">class</span> <span style="color:#2b91af;">StateManagedCollection</span>&lt;T&gt; : <span style="color:#2b91af;">IList</span>&lt;T&gt;, <span style="color:#2b91af;">ICollection</span>&lt;T&gt;, <span style="color:#2b91af;">IEnumerable</span>&lt;T&gt;, <span style="color:#2b91af;">IStateManager</span>,
    <span style="color:#2b91af;">IList</span>, <span style="color:#2b91af;">ICollection
</span>    <span style="color:#0000ff;">where</span> T : <span style="color:#0000ff;">class</span>, <span style="color:#2b91af;">IStateManagedItem</span>, <span style="color:#0000ff;">new</span>()</pre>
<p>If you are not familiar with generics and generic constraints, this is basically a list class which requires the child items to be a class (not a struct), derive from IStateManagedItem, and to have a default constructor.</p>
<p>So to create our list of Appointments, all we need to do is the following:</p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">class</span> <span style="color:#2b91af;">AppointmentCollection</span> : <span style="color:#2b91af;">StateManagedCollection</span>&lt;<span style="color:#2b91af;">Appointment</span>&gt;
{
}</pre>
<p>That is it as far as the AppointmentCollection class goes. It doesn&#8217;t require any more code.</p>
<h3>Sample Control</h3>
<p>So lets finish the example by creating a custom control which displays a list of Appointments. First we will derive from Composite Control:</p>
<pre>[<span style="color:#2b91af;">ParseChildren</span>(<span style="color:#0000ff;">true</span>), <span style="color:#2b91af;">PersistChildren</span>(<span style="color:#0000ff;">false</span>)]
<span style="color:#0000ff;">public</span> <span style="color:#0000ff;">class</span> <span style="color:#2b91af;">AppointmentControl</span> : <span style="color:#2b91af;">CompositeControl</span></pre>
<p>Note the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.parsechildrenattribute.aspx" target="_blank">ParseChildren</a> and <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.persistchildrenattribute.aspx" target="_blank">PersistChildren</a> attributes, these are required to tell Asp.Net how to parse the markup inbetween the start and end tags of your control. This is part of the &quot;Magic&quot; I mentioned earlier.</p>
<p>Next, make a member of the class which is an AppointmentCollection:</p>
<pre><span style="color:#0000ff;">private</span> <span style="color:#2b91af;">AppointmentCollection</span> appointments = <span style="color:#0000ff;">null</span>;</pre>
<p>
  <br />And a public property to access that collection: </p>
<p></p>
<pre>[
    <span style="color:#2b91af;">Mergable</span>(<span style="color:#0000ff;">false</span>),
    <span style="color:#2b91af;">PersistenceMode</span>(<span style="color:#2b91af;">PersistenceMode</span>.InnerProperty),
]
<span style="color:#0000ff;">public</span> <span style="color:#2b91af;">AppointmentCollection</span> Appointments
{
    <span style="color:#0000ff;">get
</span>    {
        <span style="color:#0000ff;">if</span> (appointments == <span style="color:#0000ff;">null</span>)
        {
            appointments = <span style="color:#0000ff;">new</span> <span style="color:#2b91af;">AppointmentCollection</span>();
            <span style="color:#0000ff;">if</span> (<span style="color:#0000ff;">base</span>.IsTrackingViewState)
            {
                appointments.TrackViewState();
            }
        }
        <span style="color:#0000ff;">return</span> appointments;
    }
}</pre>
<p>This property also must have a couple of attributes &#8211; <a href="http://msdn2.microsoft.com/en-us/library/system.componentmodel.mergablepropertyattribute.aspx" target="_blank">Mergable</a> and <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.persistencemodeattribute.aspx" target="_blank">PersistenceMode</a>. These basically tell Asp.Net and Visual Studio how to handle and persist this property.</p>
<p>To use this control, first place the proper includ directive on your page:</p>
<pre><span style="background:#ffee62;">&lt;%<span style="color:#0000ff;"></span>@</span> <span style="color:#a31515;">Register</span> <span style="color:#ff0000;">TagPrefix</span><span style="color:#0000ff;">=&quot;web&quot;</span> <span style="color:#ff0000;">Namespace</span><span style="color:#0000ff;">=&quot;Web.Example.Appointment&quot;</span> <span style="background:#ffee62;">%&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>Now we can declare our control markup as:</p>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">AppointmentControl</span> <span style="color:#ff0000;">id</span><span style="color:#0000ff;">=&quot;appointmentList&quot;</span> <span style="color:#ff0000;">runat</span><span style="color:#0000ff;">=&quot;server&quot;&gt;
</span>    <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">Appointments</span><span style="color:#0000ff;">&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">Appointment</span> <span style="color:#ff0000;">Start</span><span style="color:#0000ff;">=&quot;1/6/2007 8:00 AM&quot;</span> <span style="color:#ff0000;">End</span><span style="color:#0000ff;">=&quot;1/6/2007 11:30 AM&quot;</span> <span style="color:#ff0000;">Description</span><span style="color:#0000ff;">=&quot;Breakfast&quot;</span> <span style="color:#0000ff;">/&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">Appointment</span> <span style="color:#ff0000;">Start</span><span style="color:#0000ff;">=&quot;5/12/2007 9:30 AM&quot;</span> <span style="color:#ff0000;">End</span><span style="color:#0000ff;">=&quot;5/12/2007 9:45 AM&quot;</span> <span style="color:#ff0000;">Description</span><span style="color:#0000ff;">=&quot;Meeting&quot;</span> <span style="color:#0000ff;">/&gt;
</span>        <span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">Appointment</span> <span style="color:#ff0000;">Start</span><span style="color:#0000ff;">=&quot;5/12/2007 10:00 AM&quot;</span> <span style="color:#ff0000;">End</span><span style="color:#0000ff;">=&quot;5/12/2007 10:30 AM&quot;</span> <span style="color:#ff0000;">Description</span><span style="color:#0000ff;">=&quot;Break&quot;</span> <span style="color:#0000ff;">/&gt;
</span>    <span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">Appointments</span><span style="color:#0000ff;">&gt;
&lt;/</span><span style="color:#a31515;">web</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">AppointmentControl</span><span style="color:#0000ff;">&gt;</span></pre>
<p>I won&#8217;t go into the render code (you can download the source code to see all the gory details) but here is how the control renders:</p>
<p style="background-color:lightyellow;">You have 3 appointment(s)</p>
<ul>
<li>Breakfast &#8211; (01/06/2007 08:00:00 &#8211; 01/06/2007 11:30:00) </li>
<li>Meeting &#8211; (05/12/2007 09:30:00 &#8211; 05/12/2007 09:45:00) </li>
<li>Break &#8211; (05/12/2007 10:00:00 &#8211; 05/12/2007 10:30:00) </li>
</ul>
<p>You can download the <a title="Download Example Source Code" href="http://www.spontaneouspublicity.com/Download/StateMangedExample.zip">full source code here</a>. Hope this helps dispell some of the &quot;Magic&quot; of Asp.Net controls.</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f05%2f23%2fchild-collections-in-aspnet-custom-controls%2f"><img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f05%2f23%2fchild-collections-in-aspnet-custom-controls%2f" border="0" /></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/48/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/48/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/48/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/48/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/48/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/48/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/48/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/48/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/48/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/48/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=48&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/05/23/child-collections-in-aspnet-custom-controls/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/05/windowslivewriterchildcollectionsinasp.netcustomcontrols-94feimage0-thumb1.png" medium="image" />

		<media:content url="http://lfoust.files.wordpress.com/2007/05/windowslivewriterchildcollectionsinasp.netcustomcontrols-94feimage0-thumb3.png" medium="image" />

		<media:content url="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fblog.spontaneouspublicity.com%2f2007%2f05%2f23%2fchild-collections-in-aspnet-custom-controls%2f" medium="image">
			<media:title type="html">kick it on DotNetKicks.com</media:title>
		</media:content>
	</item>
		<item>
		<title>DelimitedList&lt;T&gt; &#8211; a useful utility class</title>
		<link>http://lfoust.wordpress.com/2007/05/22/delimitedlist-a-useful-utility-class/</link>
		<comments>http://lfoust.wordpress.com/2007/05/22/delimitedlist-a-useful-utility-class/#comments</comments>
		<pubDate>Tue, 22 May 2007 20:18:21 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/05/22/delimitedlist-a-useful-utility-class/</guid>
		<description><![CDATA[There are several classes which I have written over the years which have become almost like my own personal BCL when developing .Net projects. I think most people have these classes laying around in some form or fashion. In fact, I have joined a formalized effort led by Steve Wright to make an open source [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=42&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>There are several classes which I have written over the years which have become almost like my own personal BCL when developing .Net projects. I think most people have these classes laying around in some form or fashion. In fact, I have joined a formalized effort led by <a target="_blank" href="http://devlicio.us/blogs/steve_wright/">Steve Wright </a>to make an open source version of this &#8220;Toolbox&#8221; called <a target="_blank" href="http://www.ntoolbox.com/">nToolbox</a>. While that project is getting off the ground, I figured I might share some of the classes which have been very useful to me personally. If this topic interests you, you can read my <a href="http://lfoust.wordpress.com/2006/09/20/how-to-traverse-the-control-tree-in-aspnet-with-c-20/">previous post</a> where I shared some code which I use to find Controls on an Asp.Net page.</p>
<h3>Background</h3>
<p>Here is the situation I kept finding myself in &#8211; I will use the case of a comma delimited list of items since it is the most common scenario:</p>
<p>I want to loop through a list of strings and build a comma delimited list. The code begins something like this:</p>
<pre><span style="color:#0000ff;">string</span>[] items = <span style="color:#0000ff;">new</span> <span style="color:#0000ff;">string</span>[]
{
    <span style="color:#a31515;">"Apples"</span>,
    <span style="color:#a31515;">"Oranges"</span>,
    <span style="color:#a31515;">"Pears"</span>,
    <span style="color:#a31515;">"Bannanas"
</span>};    

<span style="color:#2b91af;">StringBuilder</span> list = <span style="color:#0000ff;">new</span> <span style="color:#2b91af;">StringBuilder</span>();       

<span style="color:#0000ff;">foreach</span> (<span style="color:#0000ff;">string</span> item <span style="color:#0000ff;">in</span> items)
{
    list.AppendFormat(<span style="color:#a31515;">"{0},"</span>, item);
}       

<span style="color:#2b91af;">Console</span>.WriteLine(list.ToString());</pre>
<p>The problem with this is it will produce the following string:</p>
<pre><span style="color:#a31515;">Apples,Oranges,Pears,Bannanas,</span></pre>
<p><a href="http://11011.net/software/vspaste"></a>Notice that there is a trailing comma on the end. So then I end up having to explicitly remove that last comma by either not adding it on the last iteration through the loop or by removing it after the loop has completed.</p>
<h3>DelimitedList</h3>
<p>So I wrote a class which will help me produce such lists but without the pain of remembering if there is a comma at the end or not. Although the DelimitedList class defaults to just having a single comma as its delimited, it can actually have any string as a delimited. I have used it in the past to delimited things by pipes &#8216;|&#8217; and even line breaks which can be useful when you want one item per line.</p>
<p>Rewriting the same code above with the delimited list would look like this:</p>
<pre><span style="color:#2b91af;">DelimitedList</span>&lt;<span style="color:#0000ff;">string</span>&gt; list = <span style="color:#0000ff;">new</span> <span style="color:#2b91af;">DelimitedList</span>&lt;<span style="color:#0000ff;">string</span>&gt;();       

<span style="color:#0000ff;">foreach</span> (<span style="color:#0000ff;">string</span> item <span style="color:#0000ff;">in</span> items)
{
    list.Add(item);
}     

<span style="color:#2b91af;">Console</span>.WriteLine(list.ToString());</pre>
<pre>Now this will produce the expected string:</pre>
<pre><span style="color:#a31515;">Apples,Oranges,Pears,Bannanas</span></pre>
<p><a href="http://11011.net/software/vspaste"></a>The DelimitedList can also work on any type of object (thus the use of Generics) so you can use it with types other than strings: (just for varieties sake, I will use a delimiter other than a comma)</p>
<pre><span style="color:#2b91af;">DelimitedList</span>&lt;<span style="color:#0000ff;">int</span>&gt; list = <span style="color:#0000ff;">new</span> <span style="color:#2b91af;">DelimitedList</span>&lt;<span style="color:#0000ff;">int</span>&gt;("+");       

<span style="color:#0000ff;">for</span> (<span style="color:#0000ff;">int</span> i = 0; i &lt; 10; i++)
{
    list.Add(i);
}       

<span style="color:#2b91af;">Console</span>.WriteLine(list);</pre>
<p>This will produce the following string:</p>
<pre><span style="color:#a31515;">0+1+2+3+4+5+6+7+8+9</span></pre>
<p>You can download the complete code for the DelimitedList class <a href="http://www.spontaneouspublicity.com/Download/DelimitedList.zip" title="Download DelimitedList.cs">here</a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/42/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/42/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/42/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/42/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/42/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/42/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/42/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/42/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/42/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/42/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=42&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/05/22/delimitedlist-a-useful-utility-class/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>YUI.Net: Calendar Control</title>
		<link>http://lfoust.wordpress.com/2007/05/21/yuinet-calendar-control/</link>
		<comments>http://lfoust.wordpress.com/2007/05/21/yuinet-calendar-control/#comments</comments>
		<pubDate>Mon, 21 May 2007 17:06:30 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[YUI.Net]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/05/21/yuinet-calendar-control/</guid>
		<description><![CDATA[The first control I will highlight in the Yui.Net control library is the calendar. I find that I often need a client side calendar control to allow users to just choose a quick date without having to deal with the overhead brought on by the Asp.Net calendar control (ViewState, Postback, etc). When I ran across the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=37&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://lfoust.files.wordpress.com/2007/05/windowslivewriteryui.netcalendarcontrol-b8c3calnder0141.png"><img border="0" align="left" width="113" src="http://lfoust.files.wordpress.com/2007/05/windowslivewriteryui.netcalendarcontrol-b8c3calnder01-thumb21.png?w=113&#038;h=115" height="115" style="border-width:0;margin:0 15px 0 0;" /></a>The first control I will highlight in the <a target="_blank" href="http://www.codeplex.com/YuiDotNet/">Yui.Net control library</a> is the <a target="_blank" href="http://developer.yahoo.com/yui/calendar/" title="YUI Calendar Control">calendar</a>. I find that I often need a client side calendar control to allow users to just choose a quick date without having to deal with the overhead brought on by the Asp.Net calendar control (ViewState, Postback, etc). When I ran across the YUI calendar I was really impressed with both its functionality as well as it customizability.</p>
<h3>The Basics</h3>
<p>In order to just get a basic calendar displayed on your page, you need to include two things:</p>
<p>1. The YahooScriptManager</p>
<blockquote>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">yui</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">YahooScriptManager</span> <span style="color:#ff0000;">ID</span><span style="color:#0000ff;">="manager"</span> <span style="color:#ff0000;">runat</span><span style="color:#0000ff;">="server"</span> <span style="color:#0000ff;">/&gt;</span></pre>
</blockquote>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>2. The Calendar Control</p>
<blockquote>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">yui</span><span style="color:#0000ff;">:</span><span style="color:#a31515;">Calendar</span> <span style="color:#ff0000;">id</span><span style="color:#0000ff;">="cal"</span> <span style="color:#ff0000;">runat</span><span style="color:#0000ff;">="server"</span> <span style="color:#0000ff;">/&gt;</span></pre>
</blockquote>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>On the server site, the Script manager generates the following code:</p>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">script</span> <span style="color:#ff0000;">src</span><span style="color:#0000ff;">="http://yui.yahooapis.com/2.2.2/build/yahoo-dom-event/yahoo-dom-event.js"</span> <span style="color:#ff0000;">type</span><span style="color:#0000ff;">="text/javascript"&gt;&lt;/</span><span style="color:#a31515;">script</span><span style="color:#0000ff;">&gt;
&lt;</span><span style="color:#a31515;">script</span> <span style="color:#ff0000;">src</span><span style="color:#0000ff;">="http://yui.yahooapis.com/2.2.2/build/calendar/calendar-min.js"</span> <span style="color:#ff0000;">type</span><span style="color:#0000ff;">="text/javascript"&gt;&lt;/</span><span style="color:#a31515;">script</span><span style="color:#0000ff;">&gt; 

&lt;</span><span style="color:#a31515;">script</span> <span style="color:#ff0000;">type</span><span style="color:#0000ff;">="text/javascript"</span> <span style="color:#ff0000;">media</span><span style="color:#0000ff;">="Screen"&gt;
function</span> SetHiddenSelectedDates(type, args, obj) {
    <span style="color:#0000ff;">var</span> txtDate1 = document.getElementById(obj.id + <span style="color:#a31515;">"_selectedDates"</span>);
    <span style="color:#0000ff;">var</span> selected = <span style="color:#a31515;">""</span>;
    <span style="color:#0000ff;">var</span> dates = obj.getSelectedDates();
    <span style="color:#0000ff;">for</span>(<span style="color:#0000ff;">var</span> i = 0; i &lt; dates.length; i++)
    {
        <span style="color:#0000ff;">var</span> month = dates[i].getMonth() + 1;
        <span style="color:#0000ff;">var</span> day = dates[i].getDate();
        <span style="color:#0000ff;">var</span> year = dates[i].getFullYear();
        selected = selected + month + <span style="color:#a31515;">"/"</span> + day + <span style="color:#a31515;">"/"</span> + year + <span style="color:#a31515;">","</span>;
    }
    txtDate1.value = selected.substring(0, selected.length - 1);
}
<span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">script</span><span style="color:#0000ff;">&gt; 

&lt;</span><span style="color:#a31515;">link</span> <span style="color:#ff0000;">href</span><span style="color:#0000ff;">="http://yui.yahooapis.com/2.2.2/build/calendar/assets/calendar.css"</span> <span style="color:#ff0000;">rel</span><span style="color:#0000ff;">="stylesheet"</span> <span style="color:#ff0000;">type</span><span style="color:#0000ff;">="text/css"</span> <span style="color:#ff0000;">media</span><span style="color:#0000ff;">="Screen"</span> <span style="color:#0000ff;">/&gt; 

&lt;</span><span style="color:#a31515;">script</span> <span style="color:#ff0000;">type</span><span style="color:#0000ff;">="text/javascript"</span> <span style="color:#ff0000;">media</span><span style="color:#0000ff;">="Screen"&gt;
</span>    <span style="color:#0000ff;">var</span> cal;
    <span style="color:#0000ff;">function</span> init() {
        cal = <span style="color:#0000ff;">new</span>  YAHOO.widget.Calendar(<span style="color:#a31515;">"cal"</span>, <span style="color:#a31515;">"cal_container"</span>, { pagedate: <span style="color:#a31515;">"05/2007"</span>} ); cal.render();cal.selectEvent.subscribe(SetHiddenSelectedDates, cal, <span style="color:#0000ff;">true</span>);
    }
    YAHOO.util.Event.addListener(window, <span style="color:#a31515;">"load"</span>, init);
<span style="color:#0000ff;">&lt;/</span><span style="color:#a31515;">script</span><span style="color:#0000ff;">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>There are <strong>3 things</strong> I would like to point out in this code (not necessarily in the order they appear):</p>
<p><strong>First</strong>, there are the includes of the yahoo-dom-event.js and the calendar-min.js files which are hosted on the yahoo servers. YUI.Net also allows you to host the files yourself if you need access to the debug scripts or if you just prefer to store the files locally. the calendar.css file is also included which contains the default styles for the calendar control.</p>
<p><strong>Second</strong>, there is the javascript initialization code in the last script block. This initializes the calendar with the default values and hooks up the event handler for the selectEvent event. This allows the calendar to store the selected dates in a hidden html field for use on the server side.</p>
<p><strong>Lastly</strong>, there is the SetHiddenSelectedDates method which is responsible for taking the selected dates and storing them as a comma delimited string in a hidden html field.</p>
<p>The calendar control renders the following html markup:</p>
<pre><span style="color:#0000ff;">&lt;</span><span style="color:#a31515;">div</span> <span style="color:#ff0000;">id</span><span style="color:#0000ff;">="cal_container"&gt;&lt;/</span><span style="color:#a31515;">div</span><span style="color:#0000ff;">&gt;&lt;</span><span style="color:#a31515;">input</span> <span style="color:#ff0000;">type</span><span style="color:#0000ff;">="hidden"</span> <span style="color:#ff0000;">name</span><span style="color:#0000ff;">="cal_selectedDates"&gt;&lt;/</span><span style="color:#a31515;">input</span><span style="color:#0000ff;">&gt;</span></pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>This is basically just the div which will contain the calendar and the hiddent field to hold the selected dates. Notice that the name of the div is the same that is passed in to the YAHOO.widget.Calendar constructor.</p>
<h3>Server Side Properties</h3>
<p><span style="color:#0000ff;">public</span> <span style="color:#2b91af;">DateTime</span>[] SelectedDates</p>
<p>This returns a list of dates currently selected. It achieves this by parsing through the hidden html field mentioned earlier which stores all of the selected dates in a comma delimited list. This property is read only.</p>
<pre><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">string</span> SelectedDateString</pre>
<p><a href="http://11011.net/software/vspaste"></a><a href="http://11011.net/software/vspaste"></a></p>
<p>This string maps to the &#8216;selected&#8217; property of the YUI calendar configuration property. (Side note: this can get a little confusing because there is a while javascript object model which does not always map directly to the sever side .Net object model). Here is an excerpt from the YUI documentation for this property:</p>
<blockquote><p>Sets the calendar&#8217;s selected dates. The built-in default date format is MM/DD/YYYY. Ranges are defined using MM/DD/YYYY-MM/DD/YYYY. Month/day combinations are defined using MM/DD. Any combination of these can be combined by delimiting the string with commas. For example: &#8220;12/24/2005,12/25/2005,1/18/2006-1/21/2006&#8243;</p></blockquote>
<p><span style="color:#0000ff;">public</span> <span style="color:#2b91af;">DateTime</span>? SelectedDate</p>
<p>Allows for a quick way to access the selected date for calendars which are limited to just one selection. A nullable date is used so a null can be returned if no date is selected.</p>
<p><span style="color:#0000ff;">public</span> <span style="color:#0000ff;">int</span> Pages</p>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>This allows support for multiple calendars in one control which appears like:</p>
<p><a href="http://lfoust.files.wordpress.com/2007/05/windowslivewriteryui.netcalendarcontrol-b8c3calnder0211.png"><img border="0" width="240" src="http://lfoust.files.wordpress.com/2007/05/windowslivewriteryui.netcalendarcontrol-b8c3calnder022.png?w=240&#038;h=125" height="125" style="border-width:0;" /></a></p>
<p>This causes the calendar to be rendered as a YAHOO.widget.CalendarGroup rather than a YAHOO.widget.Calendar. This is an example of where I have tried to make such functionality transperant to the user.</p>
<p>Here is how the rest of the properties map to the YUI javascript properties:</p>
<table width="100%">
<tr>
<th>Yui.Net Server Side Property</th>
<th>YUI client side javascript property</th>
</tr>
<tr>
<td>PageDate</td>
<td>pagedate</td>
</tr>
<tr>
<td>MinDate</td>
<td>mindate</td>
</tr>
<tr>
<td>MaxDate</td>
<td>maxdate</td>
</tr>
<tr>
<td>Title</td>
<td>title</td>
</tr>
<tr>
<td>Closable</td>
<td>close</td>
</tr>
<tr>
<td>UseIFrame</td>
<td>iframe</td>
</tr>
<tr>
<td>MultiSelect</td>
<td>MULTI_SELECT</td>
</tr>
<tr>
<td>ShowWeekdays</td>
<td>SHOW_WEEKDAYS</td>
</tr>
<tr>
<td>MonthFormat (enum)</td>
<td>LOCALE_MONTHS</td>
</tr>
<tr>
<td>WeekdayFormat (enum)</td>
<td>LOCALE_WEEKDAYS</td>
</tr>
<tr>
<td>WeekStartDay</td>
<td>START_WEEKDAY</td>
</tr>
<tr>
<td>ShowWeekHeader</td>
<td>SHOW_WEEK_HEADER</td>
</tr>
<tr>
<td>ShowWeekFooter</td>
<td>SHOW_WEEK_FOOTER</td>
</tr>
<tr>
<td>HideBlankWeeks</td>
<td>HIDE_BLANK_WEEKS</td>
</tr>
<tr>
<td>NavLeftImageUrl</td>
<td>NAV_ARROW_LEFT</td>
</tr>
<tr>
<td>NavRightImageUrl</td>
<td>NAV_ARROW_RIGHT</td>
</tr>
</table>
<p>In some cases I have renamed some properties to make them more Asp.Net like and changed thier types from numbers to enums to provide a better user experience.</p>
<p>As you can see, most of the power of this control comes from the javascript provided by Yahoo &#8211; which is why the YUI.Net is mostly a wrapper with some funcationlity added.</p>
<p style="display:inline;margin:0;padding:0;" class="wlWriterSmartContent">Technorati tags: <a rel="tag" href="http://technorati.com/tags/YUI">YUI</a>, <a rel="tag" href="http://technorati.com/tags/Asp.Net">Asp.Net</a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/37/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/37/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/37/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=37&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/05/21/yuinet-calendar-control/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/05/windowslivewriteryui.netcalendarcontrol-b8c3calnder01-thumb21.png" medium="image" />

		<media:content url="http://lfoust.files.wordpress.com/2007/05/windowslivewriteryui.netcalendarcontrol-b8c3calnder022.png" medium="image" />
	</item>
		<item>
		<title>Asp.Net Controls for the Yahoo User Interface Library</title>
		<link>http://lfoust.wordpress.com/2007/04/20/aspnet-controls-for-the-yahoo-user-interface-library/</link>
		<comments>http://lfoust.wordpress.com/2007/04/20/aspnet-controls-for-the-yahoo-user-interface-library/#comments</comments>
		<pubDate>Fri, 20 Apr 2007 17:22:35 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[YUI.Net]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/04/20/aspnet-controls-for-the-yahoo-user-interface-library/</guid>
		<description><![CDATA[I am a big fan of yahoo! and how they handle their developer resources. They release APIs for most of their services free of charge and their documentation is always top notch. One of my favorite developer resources they support is not a service but a group of javascript libraries called the Yahoo User Interface [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=30&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I am a big fan of <a target="_blank" href="http://www.yahoo.com/">yahoo!</a> and how they handle their <a target="_blank" href="http://developer.yahoo.com/">developer resources</a>. They release APIs for most of their services free of charge and their documentation is always top notch. One of my favorite developer resources they support is not a service but a group of javascript libraries called the <a target="_blank" href="http://developer.yahoo.com/yui/">Yahoo User Interface Library (YUI)</a>.</p>
<p>Not only do I like the library itself, but I really like the <a target="_blank" href="http://tech.groups.yahoo.com/group/ydn-javascript/">community around it</a>. (althought they could use a better forum than Yahoo! groups.) Like I mentioned earlier, the documentation is top notch. There is also a <a target="_blank" href="http://yuiblog.com/">blog</a> and and a <a target="_blank" href="http://developer.yahoo.com/yui/theater/">series of screencasts</a> about the YUI.  And if that isn&#8217;t enough, will now <a target="_blank" href="http://developer.yahoo.com/yui/articles/hosting/">host the files on their servers</a>.</p>
<p>Recently, I was working on an Asp.Net project where we needed some of the functionality provided by the YUI <a target="_blank" href="http://developer.yahoo.com/yui/container/">container controls</a>. Being the web control guy I am, I decided to make a control to make working with the panel controls easier.</p>
<p>Next, I realized I needed the <a target="_blank" href="http://developer.yahoo.com/yui/calendar/">calendar control</a> as well so I wrote a web control for that as well.  The next thing I knew I started writing controls to wrap the basic functionalities in many of the YUI controls and I had a class library on my hands. I have recently cleaned the code up a little bit and decided to share it with the world.</p>
<p>Keep in mind that I am not really much of a javacript expert so the client side functionality of the controls is just the bare minimum. In fact, if anybody else out there has any feedback on how I implemented the javascript, please let me know.</p>
<p>Here is the basic class diagram for what I have so far.</p>
<p><a href="http://lfoust.files.wordpress.com/2007/05/windowslivewriterasp.netcontrolsfortheyahoouserinterfacel-8218yui2.png"><img border="0" width="477" src="http://lfoust.files.wordpress.com/2007/05/windowslivewriterasp.netcontrolsfortheyahoouserinterfacel-8218yui-thumb.png?w=477&#038;h=344" height="344" style="border-width:0;" /></a></p>
<p>The inheritence heirarchy for the panels, mostly mirrors that of the YUI. The <span style="color:#2b91af;">Module </span>and <span style="color:#2b91af;">Overlay </span>classes contain functionality used by the <span style="color:#2b91af;">Menu</span>, <span style="color:#2b91af;">FloatPanel</span>, and the <span style="color:#2b91af;">Tooltip </span>controls.</p>
<h3>Architecture</h3>
<p>The basic architecture is that each control implements an interface called <span style="color:#2b91af;">IYahooControl</span>. This interface is used by the <span style="color:#2b91af;">YahooScriptManager </span>to generate the javascript needed to initialize the controls.</p>
<pre><span style="color:#0000ff;">interface</span> <span style="color:#2b91af;">IYahooControl
</span>{
    <span style="color:#0000ff;">string</span> LoadScript { <span style="color:#0000ff;">get</span>;}
    <span style="color:#2b91af;">YahooScript</span>[] ScriptScriptDependancies { <span style="color:#0000ff;">get</span>;}
    <span style="color:#2b91af;">YahooStyleSheet</span>[] StyleScriptDependancies { <span style="color:#0000ff;">get</span>;}
}</pre>
<p><a href="http://11011.net/software/vspaste"></a></p>
<p>The script manager is a non visual control that must be placed on any page which uses any of the Yahoo controls. It bascially manages all of the script references and initilization of the client side controls.</p>
<p>In most cases, I have tried to match the object model of the YUI javacript classes as closely as possible.  There are however, some exceptions. I decided to make some of the properties function more like most Asp.Net controls when it made sense. For example, the <a target="_blank" href="http://developer.yahoo.com/yui/button/">YUI Button control</a> has a <a href="http://developer.yahoo.com/yui/docs/YAHOO.widget.Button.html">property</a> called &#8216;diabled&#8217; which defaults to false but Asp.Net tends to use &#8216;Enabled&#8217; and defaults it to true. Most of these changes should be fairly small.</p>
<p>I have tried to wrap most of the panel controls into one class called FloatPanel. This control can be set to draggable and resizable which will change the actual YUI class which implements this functionality automatically.</p>
<h3>Helper Classes</h3>
<p>There are several classes which I consider just general utility classes which I included in the project just so I can use them in the control. I will do a seperate post in the future going through some of those classes and why I feel they are essential.</p>
<h3>Server Side Functionality</h3>
<p>Since the YUI controls are client side controls, they don&#8217;t really have any inherant server side functionality. I have not yet made much effort to add this functionality yet. The only exceptio is the calendar control. I added a SelectedDates property which you can use on the server side to see which dates are selected. I implemented this by added a hidden field to the form and storing the selected dates in it on the client side.  This allows me to access that on the server side when the form is posted.</p>
<h3>Future Plans</h3>
<p>The biggest weakness of the controls I have build so far is they don&#8217;t really provide an easy way to plug into the rich YUI eventing model. I have not yet decided how I am going to approach this so any feedback is definitely welcome. I have put the code up on <a target="_blank" href="http://www.codeplex.com/YuiDotNet/">CodePlex</a> so hopefully I can generate some interest and get some other developers to contribute to the project. There is another <a href="http://www.codeplex.com/GridExtender">project on CodePlex</a> related to the YUI controls which included both the Grid and the TreeView (which I have not yet implemented). I plan on taking a look at how are two libraries can possibly work together</p>
<h3>Documentation</h3>
<p>I would really like to follow in the tradition of the YUI and provide good documentation but that will have to wait until a future release.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/30/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/30/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/30/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=30&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/04/20/aspnet-controls-for-the-yahoo-user-interface-library/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2007/05/windowslivewriterasp.netcontrolsfortheyahoouserinterfacel-8218yui-thumb.png" medium="image" />
	</item>
		<item>
		<title>A New Custom WPF Panel: SpanningStackPanel</title>
		<link>http://lfoust.wordpress.com/2007/03/13/a-new-custom-wpf-panel-spanningstackpanel/</link>
		<comments>http://lfoust.wordpress.com/2007/03/13/a-new-custom-wpf-panel-spanningstackpanel/#comments</comments>
		<pubDate>Tue, 13 Mar 2007 21:15:40 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[WPF]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/03/13/a-new-custom-wpf-panel-spanningstackpanel/</guid>
		<description><![CDATA[Nick Thuesen has just published a new custom WPF panel that functions like a stack panel but takes up the entire space provided to it. I love to see new custom panels come out. I think there should be a Codeplex project for custom WPF panels. Maybe if I write any clever ones of my [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=26&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.nickthuesen.com/">Nick Thuesen</a> has just published a <a href="http://www.nickthuesen.com/?p=15">new custom WPF panel</a> that functions like a stack panel but takes up the entire space provided to it.  I love to see new custom panels come out. I think there should be a Codeplex project for custom WPF panels. Maybe if I write any clever ones of my own I will start one.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/26/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/26/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/26/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=26&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/03/13/a-new-custom-wpf-panel-spanningstackpanel/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>My version of sombody else&#8217;s code: Finding the Index of an item in a Drag Drop operation</title>
		<link>http://lfoust.wordpress.com/2007/03/06/my-version-of-sombody-elses-code-finding-the-index-of-an-item-in-a-drag-drop-operation/</link>
		<comments>http://lfoust.wordpress.com/2007/03/06/my-version-of-sombody-elses-code-finding-the-index-of-an-item-in-a-drag-drop-operation/#comments</comments>
		<pubDate>Wed, 07 Mar 2007 05:57:23 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[WPF]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2007/03/06/my-version-of-sombody-elses-code-finding-the-index-of-an-item-in-a-drag-drop-operation/</guid>
		<description><![CDATA[While working on an application that requires drag and drop, I ran into trouble when trying to figure out where in the target list (in my case, a ListBox) to insert the dropped item.&#160;I ran across Josh Smith&#8217;s article&#160;Drag and Drop Items in a WPF ListView&#160;which covers (quite nicely) how to handle drag and drop [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=25&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>While working on an application that requires drag and drop, I ran into trouble when trying to figure out where in the target list (in my case, a ListBox) to insert the dropped item.&nbsp;I ran across <a title="Josh Smith on WPF" href="http://joshsmithonwpf.wordpress.com/">Josh Smith&#8217;s</a> article&nbsp;<a title="Drag and Drop Items in a WPF ListView - The Code Project - Windows Presentation Foundation" href="http://www.codeproject.com/useritems/ListViewDragDropManager.asp">Drag and Drop Items in a WPF ListView</a>&nbsp;which covers (quite nicely) how to handle drag and drop operations within and between ListViews.&nbsp; While reading through the code, I found that he uses some code from <a title="Dan Crevier's Blog" href="http://blogs.msdn.com/dancre/">Dan Crevier</a>&nbsp;which was posted on <a href="http://blogs.msdn.com/llobo/archive/2006/09/06/Scrolling-Scrollviewer-on-Mouse-Drag-at-the-boundaries.aspx">Lester&#8217;s Blog</a>. Ok, now that I have taken you through the tangled web of other people&#8217;s code, I will share how I used the code and changed it a little to work in my situation.</p>
<p>&nbsp;</p>
<div class="wlWriterSmartContent" style="display:inline;float:none;width:691px;margin:0;padding:0;">
<pre style="background-color:White;overflow:auto;">
<div><span style="color:#000000;">        </span><span style="color:#0000FF;">public</span><span style="color:#000000;"> </span><span style="color:#0000FF;">static</span><span style="color:#000000;"> Point GetMousePosition(Visual relativeTo)
        {
            Win32Point mouse </span><span style="color:#000000;">=</span><span style="color:#000000;"> </span><span style="color:#0000FF;">new</span><span style="color:#000000;"> Win32Point();
            GetCursorPos(</span><span style="color:#0000FF;">ref</span><span style="color:#000000;"> mouse);

            System.Windows.Interop.HwndSource presentationSource </span><span style="color:#000000;">=</span><span style="color:#000000;">
                (System.Windows.Interop.HwndSource)PresentationSource.FromVisual(relativeTo);

            ScreenToClient(presentationSource.Handle, </span><span style="color:#0000FF;">ref</span><span style="color:#000000;"> mouse);

            GeneralTransform transform </span><span style="color:#000000;">=</span><span style="color:#000000;"> relativeTo.TransformToAncestor(presentationSource.RootVisual);

            Point offset </span><span style="color:#000000;">=</span><span style="color:#000000;"> transform.Transform(</span><span style="color:#0000FF;">new</span><span style="color:#000000;"> Point(</span><span style="color:#000000;">0</span><span style="color:#000000;">, </span><span style="color:#000000;">0</span><span style="color:#000000;">));

            </span><span style="color:#0000FF;">return</span><span style="color:#000000;"> </span><span style="color:#0000FF;">new</span><span style="color:#000000;"> Point(mouse.X </span><span style="color:#000000;">-</span><span style="color:#000000;"> offset.X, mouse.Y </span><span style="color:#000000;">-</span><span style="color:#000000;"> offset.Y);
        }

        </span><span style="color:#0000FF;">public</span><span style="color:#000000;"> </span><span style="color:#0000FF;">static</span><span style="color:#000000;"> </span><span style="color:#0000FF;">int</span><span style="color:#000000;"> GetIndexUnderDragCursor(ItemsControl control)
        {
            </span><span style="color:#0000FF;">int</span><span style="color:#000000;"> index </span><span style="color:#000000;">=</span><span style="color:#000000;"> </span><span style="color:#000000;">-</span><span style="color:#000000;">1</span><span style="color:#000000;">;
            </span><span style="color:#0000FF;">for</span><span style="color:#000000;"> (</span><span style="color:#0000FF;">int</span><span style="color:#000000;"> i </span><span style="color:#000000;">=</span><span style="color:#000000;"> </span><span style="color:#000000;">0</span><span style="color:#000000;">; i </span><span style="color:#000000;">&lt;</span><span style="color:#000000;"> control.Items.Count; </span><span style="color:#000000;">++</span><span style="color:#000000;">i)
            {
                </span><span style="color:#0000FF;">if</span><span style="color:#000000;"> (control.ItemContainerGenerator.Status </span><span style="color:#000000;">==</span><span style="color:#000000;"> GeneratorStatus.ContainersGenerated)
                {
                    DependencyObject item </span><span style="color:#000000;">=</span><span style="color:#000000;"> control.ItemContainerGenerator.ContainerFromIndex(i);
                    </span><span style="color:#0000FF;">if</span><span style="color:#000000;"> (IsMouseOver(item </span><span style="color:#0000FF;">as</span><span style="color:#000000;"> Visual))
                    {
                        index </span><span style="color:#000000;">=</span><span style="color:#000000;"> i;
                        </span><span style="color:#0000FF;">break</span><span style="color:#000000;">;
                    }
                }
            }
            </span><span style="color:#0000FF;">return</span><span style="color:#000000;"> index;
        }

        </span><span style="color:#0000FF;">public</span><span style="color:#000000;"> </span><span style="color:#0000FF;">static</span><span style="color:#000000;"> </span><span style="color:#0000FF;">bool</span><span style="color:#000000;"> IsMouseOver(Visual target)
        {
            </span><span style="color:#0000FF;">if</span><span style="color:#000000;"> (target </span><span style="color:#000000;">==</span><span style="color:#000000;"> </span><span style="color:#0000FF;">null</span><span style="color:#000000;">)
                </span><span style="color:#0000FF;">return</span><span style="color:#000000;"> </span><span style="color:#0000FF;">false</span><span style="color:#000000;">;
            Rect bounds </span><span style="color:#000000;">=</span><span style="color:#000000;"> VisualTreeHelper.GetDescendantBounds(target);
            Point mousePos </span><span style="color:#000000;">=</span><span style="color:#000000;"> GetMousePosition(target);
            </span><span style="color:#0000FF;">return</span><span style="color:#000000;"> bounds.Contains(mousePos);
        }
</span></div>
</pre>
<p><!-- Code inserted with Steve Dunn's Windows Live Writer Code Formatter Plugin.  http://dunnhq.com --></div>
<p>I didn&#8217;t change the GetMousePosition method at all from what I found on Lester&#8217;s blog.&nbsp; Then I slightly modified some of Josh&#8217;s code so that it is a little more general.&nbsp; I hope this helps.&nbsp; Suggestions welcome.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/25/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/25/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/25/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=25&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2007/03/06/my-version-of-sombody-elses-code-finding-the-index-of-an-item-in-a-drag-drop-operation/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Why Not</title>
		<link>http://lfoust.wordpress.com/2006/11/30/why-not/</link>
		<comments>http://lfoust.wordpress.com/2006/11/30/why-not/#comments</comments>
		<pubDate>Thu, 30 Nov 2006 14:42:25 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/11/30/why-not/</guid>
		<description><![CDATA[I&#8217;ll bite.&#160; In the name of science. http://acephalous.typepad.com/acephalous/2006/11/measuring_the_s.html<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=24&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ll bite.&nbsp; In the name of science.</p>
<p><a title="http://acephalous.typepad.com/acephalous/2006/11/measuring_the_s.html" href="http://acephalous.typepad.com/acephalous/2006/11/measuring_the_s.html">http://acephalous.typepad.com/acephalous/2006/11/measuring_the_s.html</a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/24/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/24/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/24/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=24&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/11/30/why-not/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>The Spice of Life</title>
		<link>http://lfoust.wordpress.com/2006/10/27/the-spice-of-life/</link>
		<comments>http://lfoust.wordpress.com/2006/10/27/the-spice-of-life/#comments</comments>
		<pubDate>Fri, 27 Oct 2006 14:13:56 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/10/27/the-spice-of-life/</guid>
		<description><![CDATA[Sometimes it can be a pain to subscribe to Rss feeds which are collections of many different authors.&#160; For instance, back in the day, I subscribed to the main MSDN feed and it was just to laborious sifting through all posts to find just what I was interested in.&#160; Not to mention the 100 obligatory [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=22&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Sometimes it can be a pain to subscribe to Rss feeds which are collections of many different authors.&nbsp; For instance, back in the day, I subscribed to the <a href="http://blogs.msdn.com/MainFeed.aspx?Type=AllBlogs">main MSDN feed</a> and it was just to laborious sifting through all posts to find just what I was interested in.&nbsp; Not to mention the 100 obligatory &#8220;Microsoft product [Insert Name Here] has released a new CTP&#8221; posts that happened for every release. I have since just subscribed to the authors which I found myself reading the most often.</p>
<p>I was relieved to find that the main feed at <a href="http://www.codebetter.com/">codebetter.com</a> is different. Since I subscribed to their main feed, I find almost all of the posts to be at least interesting if not very helpful and applicable.&nbsp;Why is this?&nbsp; I really don&#8217;t know.&nbsp; Maybe they are focused on a smaller number of good authors.&nbsp; The posts range from <a href="http://codebetter.com/blogs/jeremy.miller/default.aspx">jmiller&#8217;s</a> short, quick, and entertaining posts (<a href="http://codebetter.com/blogs/jeremy.miller/archive/2006/10/24/CodingLaw_2100_.aspx">CodingLaw!</a>&nbsp;and <a href="http://codebetter.com/blogs/jeremy.miller/archive/2006/10/26/There-are-two-types-of-developers-in-the-world.aspx">There are two types of developers in the world</a>) to longer, more involved posts (<a title="Scott Bellware [MVP] A Wrapper Class for Spring .NET's Inversion of Control-Dependency Injection" href="http://codebetter.com/blogs/scott.bellware/archive/2006/10/20/150642.aspx">A Wrapper Class for Spring .NET&#8217;s Inversion of Control-Dependency Injection</a>&nbsp;and <a title="Creating-an-Ad-Publishing-Application" href="http://codebetter.com/blogs/brendan.tompkins/archive/2006/10/13/Creating-an-Ad-Publishing-Application.aspx">Creating-an-Ad-Publishing-Application</a>).</p>
<p>Browse the topics covered on this site and let me know what you think!</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/22/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/22/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/22/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/22/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/22/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=22&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/10/27/the-spice-of-life/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>My Journey Through &quot;Applications = Code + Markup&quot; Part 2</title>
		<link>http://lfoust.wordpress.com/2006/10/10/my-journey-through-applications-code-markup-part-2/</link>
		<comments>http://lfoust.wordpress.com/2006/10/10/my-journey-through-applications-code-markup-part-2/#comments</comments>
		<pubDate>Tue, 10 Oct 2006 15:54:42 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/10/10/my-journey-through-applications-code-markup-part-2/</guid>
		<description><![CDATA[Ok, so I haven&#8217;t been writing as often as I had anticipated about my journey through&#160;Applications = Code + Markup&#160;by Charles Petzold.&#160; Since my last post Petzold has posted some reactions to some of the common criticisms of his book.&#160; It is definitely worth a read. I read through the first part of the book [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=21&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Ok, so I haven&#8217;t been writing as often as I had anticipated about my journey through&nbsp;<a href="http://www.amazon.com/gp/product/0735619573/ref=pd_rvi_gw_1/102-0554301-1970526?ie=UTF8">Applications = Code + Markup</a>&nbsp;by <a href="http://www.charlespetzold.com/">Charles Petzold</a>.&nbsp; Since my last post Petzold has <a href="http://www.charlespetzold.com/blog/2006/09/280145.html">posted some reactions to some of the common criticisms of his book</a>.&nbsp; It is definitely worth a read.</p>
<p>I read through the first part of the book pretty quickly.&nbsp; I would read 2 or 3 chapters while not in front of a computer and then I would find a computer and type in and run most of the samples.&nbsp;I thought it was important to type in the samples myself instead of just using the sample code you download from the <a href="http://www.microsoft.com/mspress/companion/0-7356-1957-3/">Microsoft Press&nbsp;companion&nbsp;website</a>&nbsp;so I could get used to coding in the Visual Studio Cider environment.&nbsp;I found this technique to be very effective in recognizing common mistakes and errors and learning how to fix them.</p>
<p>The pace of my reading slowed down significantly somewhere around Chapter 11: Single Child Elements or Chapter 12: Custom Panels.&nbsp; Not that the subject matter wasn&#8217;t interesting, I just found it very difficult to visualize without being around a computer to try out the samples.&nbsp;I just kept pressing though anyway with the intention of reading those chapters slower on my second pass through of the book (yes, I intend to read the entire book twice).</p>
<p>Chapter 18: The Notepad Clone was also very difficult to read.&nbsp; This sort of &#8220;Tying it all together&#8221; chapter is required in most programming books so I don&#8217;t blame the author for the excess of code in this chapter.</p>
<p>The Xaml portion of the book starts in Chapter 19.&nbsp;Once I reached this point, the book became a page turner. There are so many WPF mysteries that are being revealed I can&#8217;t even keep track of all of them.&nbsp;I found the information on Resources, Data Binding, Styles, and Templates to be fascinating.&nbsp; This, in my opinion, is where the real power of WPF is revealed.&nbsp;I have so many things I want to try using the techniques found in these sections that I am not sure when I will find the time. After I finish this book for the first time, I am going to write down all of my ideas so I can keep them in mind during my second reading.&nbsp;Stay tuned.</p>
<div class="wlWriterSmartContent" style="display:inline;margin:0;padding:0;">Technorati tags: <a href="http://technorati.com/tags/C#" rel="tag">C#</a>, <a href="http://technorati.com/tags/.Net" rel="tag">.Net</a>, <a href="http://technorati.com/tags/WPF" rel="tag">WPF</a></div>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/21/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/21/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/21/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=21&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/10/10/my-journey-through-applications-code-markup-part-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Netidentity Email Migration Nightmare: Update</title>
		<link>http://lfoust.wordpress.com/2006/10/05/netidentity-email-migration-nightmare-update/</link>
		<comments>http://lfoust.wordpress.com/2006/10/05/netidentity-email-migration-nightmare-update/#comments</comments>
		<pubDate>Thu, 05 Oct 2006 13:55:11 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/10/05/netidentity-email-migration-nightmare-update/</guid>
		<description><![CDATA[Last week I wrote about how my email provider Netidentity had completely messed up a migration with their web email system and left thousands of user without their paid for email service. Well, after 5 days with no email I did finally gain access to my email.&#160; So how did my email get fixed? Did [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=20&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Last week <a href="http://lfoust.wordpress.com/2006/09/29/netidentitycoms-email-migration-nightmare/" target="_blank">I wrote</a> about how my email provider Netidentity had completely messed up a migration with their web email system and left thousands of user without their paid for email service.</p>
<p>Well, after 5 days with no email I did finally gain access to my email.&nbsp; So how did my email get fixed? Did the people at Netidentity find the problem and fix it system wide? no. Did one of my emails or calls to support get my problem escalated to a priority and they fixed it? no.&nbsp; Did I spend days and days reading though <a href="http://www.domaindirectnews.com/" target="_blank">the blog of one of their employees</a> and all of the angry comments only to discover that I could post my email address there to get it fixed?&nbsp; Yup.</p>
<p>I am pretty sure that if I had not found the blog and read through it to figure out that netidentity was paying more attention to users problems if they post their information directly on the blog, I would still be without email.&nbsp;I can&#8217;t even imagine how this must be for the typical customer who does not read blogs or search alternative means for reaching customer service but instead just sits and waits for netidentity to fix their email.</p>
<p>So everything is fine now right?&nbsp; Wrong.&nbsp; My email worked for a couple of days and now I am getting an error message <font color="#ff0000">&#8220;An error occurred while reading your settings. Please contact your system administrator.&#8221;</font> when I try to access my web mail.</p>
<p>This is ridiculous. I guess it is time to abandon this service and search for a new one.&nbsp;I really wish they didn&#8217;t own the domain name of my last name.&nbsp; I guess I will change my last name to <em>zlkdjfaowiejfadsjf</em> and purchase the domain name right away.</p>
</p>
<div class="wlWriterSmartContent" style="display:inline;margin:0;padding:0;">Technorati tags: <a href="http://technorati.com/tags/Netidentity" rel="tag">Netidentity</a>, <a href="http://technorati.com/tags/Tucows" rel="tag">Tucows</a></div>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/20/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/20/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/20/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=20&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/10/05/netidentity-email-migration-nightmare-update/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Netidentity.com&#8217;s Email Migration Nightmare</title>
		<link>http://lfoust.wordpress.com/2006/09/29/netidentitycoms-email-migration-nightmare/</link>
		<comments>http://lfoust.wordpress.com/2006/09/29/netidentitycoms-email-migration-nightmare/#comments</comments>
		<pubDate>Fri, 29 Sep 2006 14:44:07 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/09/29/netidentitycoms-email-migration-nightmare/</guid>
		<description><![CDATA[Back in 1998 or so, I decided to see if the domain name for my last name was available for purchase.&#160;To my surprise (my last name is not that common), a company called Mailbank ha purchased the domain and was selling email addresses and web space on the domain for $5/year.&#160; That seemed like a [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=17&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Back in 1998 or so, I decided to see if the domain name for my last name was available for purchase.&nbsp;To my surprise (my last name is not that common), a company called Mailbank ha purchased the domain and was selling email addresses and web space on the domain for $5/year.&nbsp; That seemed like a small price to pay for the service so I signed up.</p>
<p>Mailbank was sold and the company became Netidenty.&nbsp; Their prices have continued to increase (I now pay like $50/year) but I stuck with the service.&nbsp; I think in the back of my mind I always hoped they would give up on the business model of mass buying tons of domain names and give up the less profitable ones.&nbsp; Since there have never been more than 2 users that I know of on the Foust.com domain, I figured there may be a chance that one day I could buy the domain.</p>
<p>In any event, the company was recently sold to Tuscows and they decided to upgrade their web mail interface.&nbsp; This is a fairly popular action for email services to make so I didn&#8217;t think much of it.&nbsp; Well, my mailbox got corrupted during the migration and now I have been without my personal email for 3 days.&nbsp; This has been a migration gone bad to say the least.&nbsp; I have placed an email and a call into support with no response.&nbsp; The only real message I get is that there are thousands of people with the same problem as me.&nbsp; Not really much of a consolation for any single person left without email for days on end when they could have settled with <a href="http://www.hotmail.com">another</a> <a href="http://www.gmail.com">email</a> <a href="http://mail.yahoo.com">service</a> for free.</p>
<p>The closest thing to customer service I have seen, are a couple of <a href="http://www.domaindirectnews.com/2006/09/domain_direct_i.html">blog</a> <a href="http://www.domaindirectnews.com/2006/09/netidentity_ema_2.html">posts</a>&nbsp;by a senior product manager.&nbsp; This has helped as far as information goes, but it doesn&#8217;t really make me, a loyal customer, very satisfied.&nbsp; It makes me especially angry when I read the following:</p>
<blockquote><p><strong>Mailbox index corruption.</strong> I have been informed that this problem has been solved. We were able to ascertain that the indexes of roughly 2500 accounts had been corrupted. Once all of the accounts were identified, it was relatively easy to fix the issue. This means that no one should be stuck on the pending migration page.</p>
</blockquote>
<p>This is absolutely not true for me and for many others according to the <a href="http://www.domaindirectnews.com/2006/09/netidentity_ema_2.html">comments of Ross&#8217; blog post</a>. You can tell a lot about a company by how they respond to crisis and I have to say that Netidentity has failed in almost every way.&nbsp; It will be interesting to see how this whole thing shakes out.</p>
<p>Here is my advice to Tuscows (the new owner of Netidenty), stop raising prices and keep the service simple and reliable.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/17/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/17/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/17/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=17&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/09/29/netidentitycoms-email-migration-nightmare/feed/</wfw:commentRss>
		<slash:comments>24</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>My Journey Through &quot;Applications = Code + Markup&quot;</title>
		<link>http://lfoust.wordpress.com/2006/09/22/my-journey-through-applications-code-markup/</link>
		<comments>http://lfoust.wordpress.com/2006/09/22/my-journey-through-applications-code-markup/#comments</comments>
		<pubDate>Fri, 22 Sep 2006 15:27:56 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/09/22/my-journey-through-applications-code-markup/</guid>
		<description><![CDATA[&#160;I finally received my copy of Applications = Code + Markup&#160;by Charles Petzold.&#160; It is rare that I buy a computer book with so much anticipation and desire to just sit down and read it cover to cover.&#160; The last time I had this feeling was with Framework Design Guidelines by Brad Abrams&#160;and Krzysztof Cwalina.&#160; [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=16&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>&nbsp;I finally received my copy of <a href="http://www.amazon.com/gp/product/0735619573/ref=pd_rvi_gw_1/102-0554301-1970526?ie=UTF8">Applications = Code + Markup</a>&nbsp;by <a href="http://www.charlespetzold.com/">Charles Petzold</a>.&nbsp; It is rare that I buy a computer book with so much anticipation and desire to just sit down and read it cover to cover.&nbsp; The last time I had this feeling was with <a href="http://www.amazon.com/Framework-Design-Guidelines-Conventions-Development/dp/0321246756/sr=1-1/qid=1158937295/ref=pd_bbs_1/102-5865522-8775331?ie=UTF8&amp;s=books">Framework Design Guidelines</a> by <a href="http://blogs.msdn.com/brada/">Brad Abrams</a>&nbsp;and <a href="http://blogs.msdn.com/KCwalina/">Krzysztof Cwalina</a>.&nbsp; That book was awesome and I definitely read it from cover to cover.</p>
<p>Petzold&#8217;s book is not the first book I have read on the&nbsp;<a href="http://wpf.netfx3.com/">Windows Presentation Foundation</a>&nbsp;- I have also read <a href="http://www.sellsbrothers.com/">Chris Sells&#8217;</a> <a href="http://www.amazon.com/Programming-Windows-Presentation-Foundation-Chris/dp/0596101139/ref=pd_bxgy_b_img_b/102-5865522-8775331?ie=UTF8">Programming Windows Presentation Foundation</a>&nbsp;which I would say was OK but not great.</p>
<p>Since it will probably take me a couple of weeks to work my way through Petzold&#8217;s book, I will just blog about my thoughts along the way.</p>
<p>First off, I love the idea of using just code and no <a href="http://en.wikipedia.org/wiki/XAML">XAML</a> during the first half of the book.&nbsp; This really drives home the idea that you should understand what XAML eventually translates to in code.&nbsp;In order to truly understand a technology like WPF, you have to start from the very basics and work your way up.&nbsp;It is such a new programming paradigm in so many ways that somebody who has experience with <a href="http://www.asp.net/">Asp.Net</a> or <a href="http://www.windowsforms.net/">Windows Forms</a> programming will not necessarily be able to transfer all of their UI knowledge to WPF that easily.</p>
<p>I do, however, have some immediate gripes with the book (albeit small ones).&nbsp; I definitely echo the sentiments found on some of the <a href="http://www.amazon.com/">Amazon.com</a> <a href="http://www.amazon.com/gp/product/customer-reviews/0735619573/ref=cm_cr_dp_pt/102-5865522-8775331?ie=UTF8&amp;n=283155&amp;s=books">reviews</a> regarding screenshots.&nbsp;I immediately noticed this books lack of any screenshots or diagrams.&nbsp; On one hand, this goes with the whole learning from scratch thing and I can see how the author may be using this as a way to encourage the readers to try out the examples for themselves.&nbsp;I just think that a book on a presentation technology could really benefit from pictures to really drive home the point.</p>
<p>Another very small gripe I have is also echoed on amazon.com: the fact that every code example in the book has 3 lines of code that are not necessary &#8211; The copyright notice.</p>
<p>
<div class="wlWriterSmartContent" style="display:inline;float:none;margin:0;padding:0;">
<pre>
<div><span style="color:#008000;">//</span><span style="color:#008000;">-------------------------------------------
</span><span style="color:#008000;">//</span><span style="color:#008000;"> ProgramName.cs (c) 2006 by Charles Petzold
</span><span style="color:#008000;">//</span><span style="color:#008000;">-------------------------------------------</span></div>
</pre>
</div>
<p>I could see including these in the downloaded example code, but to print them in the book is just redundant and really adds up as far as space.&nbsp; Hundreds of examples * 3 lines of code = many extra pages in the book.</p>
<p>I am sure I will have many more good to say about this book in the long run than bad as I really enjoy Petzold&#8217;s writing style and he is definitely very knowledgeable.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/16/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/16/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/16/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=16&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/09/22/my-journey-through-applications-code-markup/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>How to Traverse the Control Tree in Asp.Net with C# 2.0</title>
		<link>http://lfoust.wordpress.com/2006/09/20/how-to-traverse-the-control-tree-in-aspnet-with-c-20/</link>
		<comments>http://lfoust.wordpress.com/2006/09/20/how-to-traverse-the-control-tree-in-aspnet-with-c-20/#comments</comments>
		<pubDate>Wed, 20 Sep 2006 22:00:35 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/09/20/how-to-traverse-the-control-tree-in-aspnet-with-c-20/</guid>
		<description><![CDATA[I couldn&#8217;t find any easy way to traverse the entire asp .net control tree using the framework classes, so I decided to write my own implementation.&#160; In the end, I wanted to be able to traverse all of the controls and get all which are of a certain type.&#160; First, the method which traverses the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=15&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I couldn&#8217;t find any easy way to traverse the entire asp .net control tree using the framework classes, so I decided to write my own implementation.&nbsp; In the end, I wanted to be able to traverse all of the controls and get all which are of a certain type.&nbsp; First, the method which traverses the tree:</p>
<p>
<div class="wlWriterSmartContent" style="display:inline;float:none;margin:0;padding:0;">
<pre>
<div><span style="color:#0000FF;">public</span><span style="color:#000000;"> </span><span style="color:#0000FF;">static</span><span style="color:#000000;"> </span><span style="color:#0000FF;">void</span><span style="color:#000000;"> RecurseControls(ControlCollection controls, FindControlDelegate callback)
{
    </span><span style="color:#0000FF;">foreach</span><span style="color:#000000;"> (Control c </span><span style="color:#0000FF;">in</span><span style="color:#000000;"> controls)
    {
        callback(c);
        </span><span style="color:#0000FF;">if</span><span style="color:#000000;"> (c.Controls.Count </span><span style="color:#000000;">&gt;</span><span style="color:#000000;"> </span><span style="color:#000000;">0</span><span style="color:#000000;">)
        {
            RecurseControls(c.Controls, callback);
        }
    }
}</span></div>
</pre>
</div>
<p>This basically recurses through the control tree and calls a given delegate for each control found.&nbsp; Here is the delegate:</p>
<p><div class="wlWriterSmartContent" style="display:inline;float:none;margin:0;padding:0;">
<pre>
<div><span style="color:#0000FF;">public</span><span style="color:#000000;"> </span><span style="color:#0000FF;">delegate</span><span style="color:#000000;"> </span><span style="color:#0000FF;">void</span><span style="color:#000000;"> FindControlDelegate(Control control);</span></div>
</pre>
</div>
<p>To top it all off, here is the method I wrote to find all of the controls of a given type on a page:</p>
<p><div class="wlWriterSmartContent" style="display:inline;float:none;margin:0;padding:0;">
<pre>
<div><span style="color:#0000FF;">public</span><span style="color:#000000;"> </span><span style="color:#0000FF;">static</span><span style="color:#000000;"> List</span><span style="color:#000000;">&lt;</span><span style="color:#000000;">T</span><span style="color:#000000;">&gt;</span><span style="color:#000000;"> FindAllControls</span><span style="color:#000000;">&lt;</span><span style="color:#000000;">T</span><span style="color:#000000;">&gt;</span><span style="color:#000000;">(Page page)
    </span><span style="color:#0000FF;">where</span><span style="color:#000000;"> T : Control
{
    List</span><span style="color:#000000;">&lt;</span><span style="color:#000000;">T</span><span style="color:#000000;">&gt;</span><span style="color:#000000;"> controls </span><span style="color:#000000;">=</span><span style="color:#000000;"> </span><span style="color:#0000FF;">new</span><span style="color:#000000;"> List</span><span style="color:#000000;">&lt;</span><span style="color:#000000;">T</span><span style="color:#000000;">&gt;</span><span style="color:#000000;">();
    RecurseControls(page.Controls, </span><span style="color:#0000FF;">delegate</span><span style="color:#000000;">(Control c)
    {
        </span><span style="color:#0000FF;">if</span><span style="color:#000000;">(c </span><span style="color:#0000FF;">is</span><span style="color:#000000;"> T)
            controls.Add(c </span><span style="color:#0000FF;">as</span><span style="color:#000000;"> T);
    });
    </span><span style="color:#0000FF;">return</span><span style="color:#000000;"> controls;
}</span></div>
</pre>
</div>
<p>I am usually not one to use cryptic programming techniques such as inline delegates, but in this case it just made sense.&nbsp; Otherwise, I would have had to somehow share the object containing the list of found controls between two different methods.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/15/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/15/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/15/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=15&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/09/20/how-to-traverse-the-control-tree-in-aspnet-with-c-20/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>How Much Does The Name Of Your Blog Matter?</title>
		<link>http://lfoust.wordpress.com/2006/09/13/how-much-does-the-name-of-your-blog-matter/</link>
		<comments>http://lfoust.wordpress.com/2006/09/13/how-much-does-the-name-of-your-blog-matter/#comments</comments>
		<pubDate>Wed, 13 Sep 2006 16:09:27 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/09/13/how-much-does-the-name-of-your-blog-matter/</guid>
		<description><![CDATA[I have noticed a curious thing lately. The actual name of the blogs I read have to do with my perception of them. Let me explain. I use NewsGator integrated with Outlook as my rss reader. When I come into work in the morning, all of the blog posts since the end of the previous [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=14&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have noticed a curious thing lately.  The actual name of the blogs I read have to do with my perception of them.  Let me explain.  I use <a href="http://www.newsgator.com/home.aspx">NewsGator</a> integrated with Outlook as my rss reader.  When I come into work in the morning, all of the blog posts since the end of the previous work day are downloaded and they show up as unread mail in outlook.  My usual routine is to just click on &#8216;Unread Mail&#8217; and begin reading from the top down.</p>
<p>So here is the thing, since the blogs are generally sorted by their alpha numeric name, I get to the ones which are named starting with A-D much sooner than the ones that start with letters later in the alphabet.</p>
<p>So why does this matter?  Well, let me give you an example: There are at least 3 different feeds which I read which basically aggregate various stories from a round the web and report the ones they find interesting.  The first one is the one and only <a href="http://www.digg.com/">Digg</a>. I subscribe to the <a href="http://www.digg.com/rss/index.xml">front page feed</a> as a way to keep up with what the Digg community deems as interesting or important. The content of this feed can be both interesting and very annoying (but that is a different top altogether).  The next feed is <a href="http://www.gizmodo.com/">Gizmodo&#8217;s</a> <a href="http://gizmodo.com/index.xml">main feed</a>.  This feed consists of anything and everything having to do with gadgets.  The third &#8220;catch all&#8221; feed is the <a href="http://www.techmeme.com/index.xml">main feed</a> on <a href="http://www.techmeme.com/">Techmeme</a>.  This site just basically aggregates what is currently popular in the <a href="http://en.wikipedia.org/wiki/Blogosphere">blogosphere</a>.  These topics tend to be mostly techy and geeky in content.</p>
<p>The thing is, the content of these three feeds sometimes overlaps.</p>
<p><a href="http://lfoust.files.wordpress.com/2006/09/WindowsLiveWriter/HowMuchDoesTheNameOfYourBlogMatter_793D/BlogNameOverlap%5B11%5D.png"><img src="http://lfoust.files.wordpress.com/2006/09/WindowsLiveWriter/HowMuchDoesTheNameOfYourBlogMatter_793D/BlogNameOverlap_thumb%5B7%5D.png?w=346&#038;h=325" height="325" width="346" /></a></p>
<p>So if the same story is in all three feeds, I tend to see it in Digg first and Techmeme last.  Does this mean that Tecmeme is somehow delivering me old information? No, but it tends to appear that way.  I have noticed that when I am looking through my blog feeds I read Digg items more closely but by the time I get to the end and I am on the Techmeme feed, I am less interested and I tend to skim more than read.  Over time, this makes Digg seem more &#8220;cool&#8221; and up to date than Techmeme in my mind.  Does anybody else run into this problem? I guess I should rename my blog &#8220;Aardvark&#8217;s Antics&#8221;.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/14/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/14/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/14/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=14&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/09/13/how-much-does-the-name-of-your-blog-matter/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>

		<media:content url="http://lfoust.files.wordpress.com/2006/09/WindowsLiveWriter/HowMuchDoesTheNameOfYourBlogMatter_793D/BlogNameOverlap_thumb%5B7%5D.png" medium="image" />
	</item>
		<item>
		<title>You Had Better Watch What You Say In Public</title>
		<link>http://lfoust.wordpress.com/2006/08/15/you-had-better-watch-what-you-say-in-public/</link>
		<comments>http://lfoust.wordpress.com/2006/08/15/you-had-better-watch-what-you-say-in-public/#comments</comments>
		<pubDate>Tue, 15 Aug 2006 10:11:40 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Funny]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/08/15/you-had-better-watch-what-you-say-in-public/</guid>
		<description><![CDATA[I just recently discovered a couple of websites that have completely changed the way I think about life in this Wikipedia/Digg/YouTube society we are now living in. The sites I have discovered came from listening to Scott Hanselman&#8217;s podcast called Hanselminutiae #2. In this podcast, he mentions a site called http://www.overheardinnewyork.com/. The idea is this: [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=13&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I just recently discovered a couple of websites that have completely changed the way I think about life in this <a href="http://www.wikipedia.org/">Wikipedia</a>/<a href="http://www.digg.com/">Digg</a>/<a href="http://www.youtube.com/">YouTube</a> society we are now living in.  The sites I have discovered came from listening to <a href="http://www.hanselman.com/blog/">Scott Hanselman&#8217;s</a> <a href="http://www.hanselminutes.com/">podcast</a> called <a href="http://www.hanselminutes.com/default.aspx?showID=31">Hanselminutiae #2.</a>  In this podcast, he mentions a site called <a href="http://www.overheardinnewyork.com/">http://www.overheardinnewyork.com/</a>.  The idea is this: You are anywhere in New York City and you hear somebody say something that you think is funny so you go to their website and write about it.  Pretty simple huh?</p>
<p>So now, when I see somebody walking down the street talking on their cell phone like they would in their own living room, I can&#8217;t help but with there were an over hear in San Diego.  It turns out there are a couple of other sites related to the New York one: <a href="http://www.overheardintheoffice.com">Overheard in the Office</a> and <a href="http://www.overheardatthebeach.com">Overheard at the Beach</a>.  According to <a href="http://en.wikipedia.org/wiki/Overheard_in_New_York">Wikipedia,</a> there are other sites like this out there.  Since all this data is available via rss, it can be aggregated.  This idea is demonstrated on the <a href="http://maps.google.com">Google Maps</a> mashup which combines the <a href="http://persistent.info/">Over Heard In New York data with Google Maps</a>.</p>
<p>So I guess this is the end of me talking about my penchant for <a href="http://en.wikipedia.org/wiki/Naked_mole_rat">naked mole rats</a> and <a href="http://www.m-w.com/dictionary/Cock-a-hoop">Cock-a-hoop</a> in public lest I be made fun of.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/13/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/13/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/13/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=13&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/08/15/you-had-better-watch-what-you-say-in-public/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Snakes on a Phone</title>
		<link>http://lfoust.wordpress.com/2006/08/14/snakes-on-a-phone/</link>
		<comments>http://lfoust.wordpress.com/2006/08/14/snakes-on-a-phone/#comments</comments>
		<pubDate>Mon, 14 Aug 2006 16:10:01 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Funny]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/08/14/snakes-on-a-phone/</guid>
		<description><![CDATA[I doubt I will go to see this movie in the theaters, but you have to admit the marketing and internet buzz aboust Snakes On A Plane has been pretty amazing.&#160; The best part?&#160; You can have Samuel L. Jackson&#160;call anybody you like and&#160;remind them to see the movie.&#160; (digg)<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=12&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I doubt I will go to see this movie in the theaters, but you have to admit the marketing and internet buzz aboust <a href="http://www.snakesonaplane.com/">Snakes On A Plane</a> has been pretty amazing.&nbsp; The best part?&nbsp; You can have <a href="http://www.imdb.com/name/nm0000168/">Samuel L. Jackson</a>&nbsp;call anybody you like and&nbsp;<a href="http://snakesonaplane.varitalk.com/">remind them to see the movie.</a>&nbsp;</p>
<p><a href="http://digg.com/movies/Get_a_call_from_Samuel_L_Jackson">(digg)</a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/12/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/12/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/12/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=12&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/08/14/snakes-on-a-phone/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>A Little Birdie Told Me About Steve Jobs</title>
		<link>http://lfoust.wordpress.com/2006/08/10/a-little-birdie-told-me-about-steve-jobs/</link>
		<comments>http://lfoust.wordpress.com/2006/08/10/a-little-birdie-told-me-about-steve-jobs/#comments</comments>
		<pubDate>Thu, 10 Aug 2006 07:55:00 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/1969/12/31/a-little-birdie-told-me-about-steve-jobs/</guid>
		<description><![CDATA[I wanted to write my views on the whole Windows Vista vs. Mac OS Leopard but Paul Thurrott has done a better job than I could have ever dream in his article Apple Mac OS X Leopard Preview: Who&#8217;s the Copycat Now?. It is good to know that somebody can still be objective and seek [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=10&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I wanted to write my views on the whole Windows Vista vs. Mac OS Leopard but Paul Thurrott has done a better job than I could have ever dream in his article <a href="http://www.winsupersite.com/showcase/macosx_leopard_preview.asp">Apple Mac OS X Leopard Preview: Who&#8217;s the Copycat Now?</a>.  It is good to know that somebody can still be objective and seek truth in the OS religious wars.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/10/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/10/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/10/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/10/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/10/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=10&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/08/10/a-little-birdie-told-me-about-steve-jobs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Buy Our Condo</title>
		<link>http://lfoust.wordpress.com/2006/06/26/buy-our-condo/</link>
		<comments>http://lfoust.wordpress.com/2006/06/26/buy-our-condo/#comments</comments>
		<pubDate>Mon, 26 Jun 2006 03:59:00 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Personal]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/1969/12/31/buy-our-condo/</guid>
		<description><![CDATA[Hey, if Robert Scoble can do it, why can’t I? We have done a lot of work on our place but now we have the chance to buy a house. So here is our Condo for Sale.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=9&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hey, if <a href="http://scobleizer.wordpress.com/2006/06/26/buy-our-house/">Robert Scoble can do it</a>, why can’t I? We have done a lot of work on our place but now we have the chance to buy a house.  So here is our <a href="http://listings1.sandicor.com/SearchDetail/Scripts/PrtBuyFul/PrtBuyFul.asp?prp=mls&amp;AgentId=612082&amp;EmailKey=34016518">Condo for Sale</a>.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/9/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/9/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/9/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/9/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/9/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=9&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/06/26/buy-our-condo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Greg Laswell</title>
		<link>http://lfoust.wordpress.com/2006/05/25/greg-laswell/</link>
		<comments>http://lfoust.wordpress.com/2006/05/25/greg-laswell/#comments</comments>
		<pubDate>Thu, 25 May 2006 06:56:00 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/1969/12/31/greg-laswell/</guid>
		<description><![CDATA[Back in college, I saw these 3 guys with guitars playing these catchy songs at some event and I was immediately hooked. I went to watch that same band, known as Simpl, many times in coffee shops and such. The three members were Tim Timmons, Chad Lansford, and Greg Laswell. Greg and Chad later went [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=8&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Back in college, I saw these 3 guys with guitars playing these catchy songs at some event and I was immediately hooked.  I went to watch that same band, known as Simpl, many times in coffee shops and such.  The three members were Tim Timmons, <a href="http://www.myspace.com/chadl">Chad Lansford</a>, and <a href="http://www.greglaswell.com/">Greg Laswell</a>.  Greg and Chad later went on to form a band called Shillglen.</p>
<p>I used to go to pretty much every Shillglen show I could make it to.  I remember thinking, &ldquo;Why wouldn&rsquo;t I jump at any chance I get to go see great music? Who Wouldn&rsquo;t?&rdquo; Over time, I sort of got to know the guys in the band.  I was the weird guy who came to all their shows. We would even record some of them. It didn&rsquo;t seem too weird at the time &ndash; we were just having fun.  In retrospect, it probably was.</p>
<p>Well, now Greg Laswell is out on his own and big things are starting to happen for him.  He <a href="http://www.greglaswell.com/newsItem.asp?page=news&amp;id=93">signed a record deal</a> with <a href="http://www.vanguardrecords.com/">Vanguard Records</a>, he has a video on <a href="http://www.vh1.com/artists/az/laswell__greg/artist.jhtml">VH1</a>, and he is even producing an album for <a href="http://www.minniedriver.com/">Minnie Driver</a>.  His solo shows are very heartfelt and his songwriting is better than ever.  You can check him out at his official website <a href="http://www.greglaswell.com">http://www.greglaswell.com</a> or on <a href="http://www.myspace.com/greglaswell">myspace</a>.</p>
<p>One of these days I am going to take all those Shillglen recordings I have and digitize them.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/8/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/8/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/8/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=8&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/05/25/greg-laswell/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Data Binding in Windows Presentation Foundation</title>
		<link>http://lfoust.wordpress.com/2006/05/25/data-binding-in-windows-presentation-foundation/</link>
		<comments>http://lfoust.wordpress.com/2006/05/25/data-binding-in-windows-presentation-foundation/#comments</comments>
		<pubDate>Thu, 25 May 2006 03:30:00 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/1970/01/01/data-binding-in-windows-presentation-foundation/</guid>
		<description><![CDATA[Hopefully this is just part of the pains associated with trying to use beta software, but I can&#39;t find good documentation on data binding in Windows Presentation Foundation. I have found multiple examples of how easy it is to bind to an Xml data source but I have never had a need to bind to [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=5&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hopefully this is just part of the pains associated with trying to use beta software, but I can&#39;t find good documentation on data binding in Windows Presentation Foundation. I have found <a href="http://www.microsoft.com/products/expression/en/interactive_designer/demos.mspx" title="Expression Training Videos" target="_blank">multiple</a> <a href="http://channel9.msdn.com/Showpost.aspx?postid=110378">examples</a> of how easy it is to bind to an Xml data source but I have never had a need to bind to Xml data. I guess if I was writing an Rss centric app, it would be really useful. I am trying to figure out how to just bind to business objects or a database.</p>
<p>I can tell from the Xml examples I have found, that data binding is more powerful than ever.  It just looks a little complicated when you have multiple ways of writing declarative data binding (verbose and shortcut).</p>
<p>I have just now started my journey of learning the WinFX world.  I have a Windows Communication Foundation (WCF) app started but have run into troubles there as well.  (I will explain that in a future blog post)  So far, I am very excited about the next generation of Windows and .Net development.  It will be very interesting to see what types of applications come out of these new technologies after the dust settles.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/5/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/5/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/5/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=5&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/05/25/data-binding-in-windows-presentation-foundation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Using Reflection in Asp.Net 2.0 Web Applications</title>
		<link>http://lfoust.wordpress.com/2006/02/27/using-reflecion-in-aspnet-20-web-applications/</link>
		<comments>http://lfoust.wordpress.com/2006/02/27/using-reflecion-in-aspnet-20-web-applications/#comments</comments>
		<pubDate>Mon, 27 Feb 2006 17:18:17 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/02/27/using-reflecion-in-aspnet-20-web-applications/</guid>
		<description><![CDATA[I have been searching far and wide for this solution for a long time and I just sort of happened upon it&#8230;so I thought I would share it here. One of the big changes from Asp.Net 1.1 to 2.0 was the format of their web projects. I actually really like the new format alot. There [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=4&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have been searching far and wide for this solution for a long time and I just sort of happened upon it&#8230;so I thought I would share it here.</p>
<p>One of the big changes from Asp.Net 1.1 to 2.0 was the format of their web projects.  I actually really like the new format alot.  There was, however, one problem that I could not get past.  I have written various &#8220;plug-in&#8221; type frameworks where you specify classes in an xml file which are loaded at runtime.  The xml usually looks something like this:</p>
<p><font color="#0000ff" size="2">Item</font><font color="#0000ff" size="2"> </font><font color="#ff0000" size="2">assembly</font><font color="#0000ff" size="2">=</font><font size="2">&#8220;</font><font color="#0000ff" size="2">myAssembly</font><font size="2">&#8220;</font><font color="#0000ff" size="2"> </font><font color="#ff0000" size="2">class</font><font color="#0000ff" size="2">=</font><font size="2">&#8220;</font><font color="#0000ff" size="2">myClass</font><font size="2">&#8220;</font><font color="#0000ff" size="2"> /&gt;</font></p>
<p>so at runtime I just have to load the given assembly and then I can create an instance of the given class.  The problem with the new web project format is that you don&#8217;t really have control over your web project assembly name like you used to in Asp .net 1.1.  So, here ist he trick I learned:</p>
<p>Assembly assembly = Assembly.Load(&#8220;App_Code&#8221;);</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/4/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/4/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/4/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=4&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/02/27/using-reflecion-in-aspnet-20-web-applications/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
		<item>
		<title>Funny, useless sites</title>
		<link>http://lfoust.wordpress.com/2006/01/18/funny-useless-sites/</link>
		<comments>http://lfoust.wordpress.com/2006/01/18/funny-useless-sites/#comments</comments>
		<pubDate>Wed, 18 Jan 2006 21:37:26 +0000</pubDate>
		<dc:creator>Luke Foust</dc:creator>
				<category><![CDATA[Funny]]></category>

		<guid isPermaLink="false">http://lfoust.wordpress.com/2006/01/18/funny-useless-sites/</guid>
		<description><![CDATA[I love the fact that people spend so much time and effort just to humor others. http://www.stuffonmycat.com http://www.chucknorrisfacts.com<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=3&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I love the fact that people spend so much time and effort just to humor others.</p>
<ul>
<li><a href="http://www.stuffonmycat.com">http://www.stuffonmycat.com</a></li>
<li><a href="http://www.chucknorrisfacts.com">http://www.chucknorrisfacts.com</a></li>
</ul>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/lfoust.wordpress.com/3/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/lfoust.wordpress.com/3/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/lfoust.wordpress.com/3/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/lfoust.wordpress.com/3/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/lfoust.wordpress.com/3/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/lfoust.wordpress.com/3/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/lfoust.wordpress.com/3/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/lfoust.wordpress.com/3/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/lfoust.wordpress.com/3/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/lfoust.wordpress.com/3/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=lfoust.wordpress.com&amp;blog=73548&amp;post=3&amp;subd=lfoust&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://lfoust.wordpress.com/2006/01/18/funny-useless-sites/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/44a71cbfdb672befcb01b103a05b4c79?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">lfoust</media:title>
		</media:content>
	</item>
	</channel>
</rss>
