<?xml version="1.0" encoding="UTF-8"?>
<rss 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:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Aaron Lerch</title>
	<atom:link href="http://www.aaronlerch.com/blog/wp-rss2.php" rel="self" type="application/rss+xml" />
	<link>http://www.aaronlerch.com/blog</link>
	<description />
	<pubDate>Sat, 01 Nov 2008 15:12:37 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
	<language>en</language>
			<geo:lat>39.866913</geo:lat><geo:long>-86.123236</geo:long><creativeCommons:license>http://creativecommons.org/licenses/by/2.5/</creativeCommons:license><item>
		<title>Run ASP.NET MVC on Windows Azure</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/438761618/</link>
		<comments>http://www.aaronlerch.com/blog/2008/11/01/run-aspnet-mvc-on-windows-azure/#comments</comments>
		<pubDate>Sat, 01 Nov 2008 05:23:31 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[asp.net mvc]]></category>

		<category><![CDATA[azure]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/11/01/run-aspnet-mvc-on-windows-azure/</guid>
		<description><![CDATA[If you’ve purposefully been ignoring the announcements out of PDC, I don’t blame you one bit. Everybody knew it would be the unveiling of Microsoft’s “cloud computing” initiative, and just about the only thing we didn’t know was the official name of it: Windows Azure. And of course I pronounce it wrong every time (I [...]]]></description>
			<content:encoded><![CDATA[<p>If you’ve purposefully been ignoring the announcements out of PDC, I don’t blame you one bit. Everybody knew it would be the unveiling of Microsoft’s “cloud computing” initiative, and just about the only thing we didn’t know was the official name of it: Windows Azure. And of course I pronounce it wrong every time (I say “ah-<em>jour</em>”, as in “soup-de-jour”). It’s hard to call it “initiative” when they’re the 3rd one to bring a product to the table. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>One thing I was looking forward to was hearing about the ASP.NET MVC story on Azure. So color me surprised when I found out there wasn’t one. Since ASP.NET MVC is bin-deployable it shouldn’t be impossible, and doing some quick searches didn’t retrieve any results showing anybody else having tried this. Of course <em>later</em> I discovered that Phil and Eilon had whipped up a sample app that ran ASP.NET MVC on Azure, but was pleased to find out that the <a href="http://blogs.msdn.com/jnak/archive/2008/10/28/asp-net-mvc-projects-running-on-windows-azure.aspx">downloadable sample app</a> didn’t work. In fact, it seemed to just be MVC stuff slapped into a WebRole project. (I’m guessing something got “lost in translation” since it wasn’t Phil or Eilon that posted the code.)</p>
<p>Anyway, here’s how you can get ASP.NET MVC up and running on Azure. I’ve created a Visual Studio template for this to make it easy to set up - <a href="http://s3.amazonaws.com:80/aaronlerch.com/files/ASP_NET_MVC_Web_Role.zip"><strong>download it here</strong></a>. To avoid distributing code that isn’t my own (i.e. Windows Azure SDK Samples) there are a few steps you’ll have to take. I’m presuming that you’ve already installed the <a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=BB893FB0-AD04-4FE8-BB04-0C5E4278D3E9&amp;displaylang=en">Windows Azure SDK</a> and the <a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=63D0D248-1B08-4F7D-ABDE-62EB75CB1E69&amp;displaylang=en">Azure Visual Studio tools</a>.</p>
<p>One thing that running a web application “in the cloud” means is that you can instantly scale higher by adding more “instances”. This means the leaky-as-a-sieve abstraction of “session state” isn’t immediately available (finally!) since any given HTTP request could be going to a different server. The default session state provider for ASP.NET is an in-memory provider. This assumes that every request comes to the same physical machine. Session state providers have varied in their reliability and handling of scalability, but the other built-in providers include an out-of-proc provider (still same machine, but more resilient to IIS going up and down) and a SQL Server provider. None of these are enabled on the Azure platform, for good reason.</p>
<p>The limitation of zero session state wouldn’t matter except that ASP.NET MVC includes the concept of “Temp Data”, which is data persisted in one request and made available to <em>the next request only</em>. By default, MVC uses the session to store this data.</p>
<p><em>Aside: like it does everywhere else, ASP.NET MVC allows you to swap out default implementations for TempData persistence. A better solution than what I have below is to specifically implement a TempDataProvider that uses the Azure data storage capabilities. Look for that soon. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </em></p>
<p>Fortunately for us the Windows Azure SDK includes some “samples”, including full implementations of membership, profile, and session providers built on the Azure data storage platform. So let’s hack those in to fulfill the default requirements of ASP.NET MVC. The only thing that I’ll say about this is that much of this stuff had better be baked into the SDK/platform by the time it goes GA. This is just a CTP, and Microsoft has been doing better at earlier community releases, so I’ll cut them some slack. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> But this is <strong>way</strong> to much work to be a reasonable shipped solution.</p>
<h4>Unzip the “samples.zip” file in the Azure SDK and build the “AspProviders” application.</h4>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_sample_location.png" /></p>
<p>They’ve conveniently included “buildme.cmd” batch files, but I built the application using Visual Studio since I like to see more of “what’s going on” (even though I really don’t see more, per se).</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_build_sample.png" /></p>
<h4>Create the required tables in the Azure Development Storage.</h4>
<p>Open the Azure SDK command prompt under your start menu, and navigate to the directory containing the AspProviders output. Run the command “devtablegen” passing in the assembly name “AspProviders.dll”. This command creates the appropriate database structures to persist objects that meet certain criteria. Run devtablegen with no parameters for a short description, or check out the documentation for more info as well.</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_devtablegen.png" /></p>
<p>You’ll get a confirmation window that displays progress and shows that the table was created successfully.</p>
<h4>Start the Development Storage service.</h4>
<p>By now, the storage service should be running, but you’ll need to explicitly enable its endpoints. Open the UI from the system tray icon (<img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_development_storage_icon.png" />), and click “Start”. If you’ve never started it before, it will ask you for the name of the database – select “AspProviders”.</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_development_storage.png" /></p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_database_selection.png" /></p>
<h4>Create a new Cloud Service and add an “ASP.NET MVC Web Role” project.</h4>
<p><a href="http://s3.amazonaws.com:80/aaronlerch.com/files/ASP_NET_MVC_Web_Role.zip"><strong>Download the Visual Studio template I created here.</strong></a> Import the template by copying the downloaded .zip file to “My Documents\Visual Studio 2008\Templates\Project Templates” (or whatever you have specified in Tools – Options – Projects and Solutions – General). Create a new “Blank Cloud Service” project.</p>
<p>&#160;<img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_cloud_service.png" /></p>
<p>Add a new “ASP.NET MVC Web Role” project using the installed template.</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_web_role.png" /></p>
<p>Your VS solution should now approximate this:</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_project_layout.png" /></p>
<p>Under the “Cloud Service” project, right-click on the “Roles” folder and select “Add &gt; Web Role Project in solution…” and select the web role project we just added.</p>
<h4>Cleanup</h4>
<p>Because I can’t distribute the compiled version of the sample app, and because the location of it on your drive depends entirely on your personal preferences, you’ll have to re-add the references manually. From the ASP.NET MVC Web Role project we added, delete the references to AspProviders and StorageClient</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_references.png" /></p>
<p>and re-add the references pointing to the assemblies we built above.</p>
<p>Press F5, and you’re up and running the default ASP.NET MVC sample app on the Windows Azure platform! From there the sky’s the limit. Or maybe “the cloud’s the limit”?</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/asp_net_azure_final.png" /></p>
<div class="wlWriterEditableSmartContent" id="scid:C16BAC14-9A3D-4c50-9394-FBFEF7A93539:9393a903-6e50-4089-877b-3a9699fc7c80" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"><a href="http://www.dotnetkicks.com/kick/?url=http://www.aaronlerch.com/blog/2008/11/01/run-aspnet-mvc-on-windows-azure/"><img src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http://www.aaronlerch.com/blog/2008/11/01/run-aspnet-mvc-on-windows-azure/" border="0" alt="kick it on DotNetKicks.com" /></a></div>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=fNbVzB"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=fNbVzB" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=KsKsn"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=KsKsn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=M4XyN"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=M4XyN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=a0Fyn"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=a0Fyn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=cyG3n"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=cyG3n" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/438761618" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/11/01/run-aspnet-mvc-on-windows-azure/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/11/01/run-aspnet-mvc-on-windows-azure/</feedburner:origLink></item>
		<item>
		<title>The Aaron and Mike Show</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/431283805/</link>
		<comments>http://www.aaronlerch.com/blog/2008/10/24/the-aaron-and-mike-show/#comments</comments>
		<pubDate>Sat, 25 Oct 2008 01:48:03 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[aaron and mike show]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/10/24/the-aaron-and-mike-show/</guid>
		<description><![CDATA[I wasn’t going to say anything until we had another show or two under our belt (for your sake, poor innocent reader!) but Mike let the cat out of the bag. He’s much crueler than I am.  
I recently heard a reading of an essay where the author said that the reason children create [...]]]></description>
			<content:encoded><![CDATA[<p>I wasn’t going to say anything until we had another show or two under our belt (for your sake, poor innocent reader!) but <a href="http://ilikeellipses.com/">Mike</a> let the <a href="http://ilikeellipses.com/2008/10/24/the-aaron-and-mike-show-1/">cat out of the bag</a>. He’s much crueler than I am. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>I recently heard a reading of an essay where the author said that the reason children create so much art is that <em>they don’t know that they’re bad at it</em>. That’s so true. And yet I love walking through my 4-year old daughter’s pre-school looking at the dozens and dozens of masterpieces posted on the walls.</p>
<p>There is something about society, peer pressure, fear of failure, etc. that keeps us from trying things because we’re not good at it. “I wish I was good at that,” we tell ourselves. But we get into a race condition where we demand excellence from ourselves before we can start, yet we need to start to achieve that excellence.</p>
<p>Enough psychobabble - what am I getting at, anyway? It’s the <a href="http://www.aaronlerch.com/blog/live/">Aaron and Mike Show</a>. My friend and coworker Mike and I decided we’d take no more than 15 minutes on a Thursday afternoon (4PM EST) and broadcast a “show” <em>LIVE</em> right from my office. We’ll talk about software and the craft of building software. Imagine it like an even shorter <a href="http://www.hanselminutes.com/">Hanselminutes</a>. Not the Hanselminutes of late, which are just interviews, nay, it’s more like the old-school Hanselminutes from way back yonder when Scott was building products for <a href="http://www.corillian.com/">Corillian</a> and talked about the real development challenges he faced every day. <em>(Both styles of Hanselminutes are good, but each serves/served a different purpose.)</em> </p>
<p>Mike and I will be talking about the development challenges we run across every day, as well as the kinds of things we are continually doing to improve our skill at the craft of software. It’ll be hard to fit it into 15 minutes but we will do our best. Each show will be recorded, so if you can’t make it to the live show, you can still see the recorded version later, and I’ll put up a blog post for each show with notes, follow-ups, etc.</p>
<p>Our first show (<a href="http://www.aaronlerch.com/blog/live/show-1/">view it here</a>) was SPECTACULAR! Just look at the kind of feedback we received:</p>
<blockquote><p>I expect this to be spectacularly lame <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> (getting popcorn)      <br />- <a href="http://twitter.com/subdigital/statuses/972552902">subdigital</a></p>
<p>thanks for your first show! Looks nice, a bit flaky though. But the effort is much appreciated. We all should start doing this!      <br />The deep insights you guys raised OTOH completely made up for the flakiness       <br />- <a href="http://twitter.com/azuidhof/status/973502317">azuidhof</a> (<a href="http://twitter.com/azuidhof/status/973578715">2nd tweet</a>)</p>
</blockquote>
<p>Okay, so it was a little rough. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> But we’re new at this, we had fun doing it, and I’m looking forward to getting better as we go along.</p>
</p>
<p><embed flashvars="autoplay=false" width="400" height="320" allowfullscreen="true" allowscriptaccess="always" src="http://www.ustream.tv/flash/video/808022" type="application/x-shockwave-flash" /><a href="http://www.ustream.tv/" style="padding:2px 0px 4px;width:400px;background:#FFFFFF;display:block;color:#000000;font-weight:normal;font-size:10px;text-decoration:underline;text-align:center;" target="_blank">Live video chat by Ustream</a>   <br /><em>Note that the broadcasting software has two buttons: Broadcast and Record. Yours truly forgot to hit Record after I hit Broadcast, so we missed recording the first few minutes. Sorry ‘bout that!</em></p>
</p>
<p></embed>
</p>
</p>
<p>Please leave us feedback with ideas of what you’d like us to talk about. You can leave a comment on this post if you like. We’ll be having the occasional guest on the show (our co-workers) to share something going on in their world of software.</p>
<p><strong>My main question for you is, will you still respect me in the morning? <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </strong></p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=gKx4hz"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=gKx4hz" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=V1J9m"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=V1J9m" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=skChM"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=skChM" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=oWhHm"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=oWhHm" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=jAWrm"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=jAWrm" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/431283805" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/10/24/the-aaron-and-mike-show/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/10/24/the-aaron-and-mike-show/</feedburner:origLink></item>
		<item>
		<title>Indy Tech Fest Slides</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/412513762/</link>
		<comments>http://www.aaronlerch.com/blog/2008/10/06/indy-tech-fest-slides/#comments</comments>
		<pubDate>Mon, 06 Oct 2008 06:06:37 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[asp.net mvc]]></category>

		<category><![CDATA[community]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/10/06/indy-tech-fest-slides/</guid>
		<description><![CDATA[I really enjoyed giving my talk on ASP.NET MVC at Indy Tech Fest this year. Thanks to all who came! I think there were 75-100 people there.
A poll at the beginning showed that most people in attendance had done some sort of web development, about a third had done ASP.NET development, and 2 people had [...]]]></description>
			<content:encoded><![CDATA[<p>I really enjoyed giving my talk on ASP.NET MVC at Indy Tech Fest this year. Thanks to all who came! I think there were 75-100 people there.</p>
<p>A poll at the beginning showed that most people in attendance had done some sort of web development, about a third had done ASP.NET development, and 2 people had worked with ASP.NET MVC. The most challenging thing was that almost everybody was unfamiliar with the MVC pattern. And yet again I learned the difference between a master and a wanna-be. A master can take complex principles and concepts and express them in a simple form that people can immediately understand. I, on the other hand, cannot. I seemed to struggle with getting the “core concepts” of ASP.NET MVC across in a way that was clear and unambiguous.</p>
<p>I’ve created a slideshare presentation with the slides. It’s an overview, and I only had time to cover a few aspects of it, but I’m still sure I was off on a few concepts – if you notice something, leave a comment so I can learn!</p>
<div id="__ss_638175" style="width: 425px; text-align: left"><a title="Indy Tech Fest 2008 - ASP.NET MVC" style="display: block; margin: 12px 0px 3px; font: 14px helvetica,arial,sans-serif; text-decoration: underline" href="http://www.slideshare.net/aaronlerch/indy-tech-fest-2008-aspnet-mvc-presentation?type=powerpoint">Indy Tech Fest 2008 - ASP.NET MVC</a><object style="margin:0px" width="425" height="355"><param name="movie" value="http://static.slideshare.net/swf/ssplayer2.swf?doc=indytechfest-2008-aspnet-mvc-published-1223261777987020-9&amp;stripped_title=indy-tech-fest-2008-aspnet-mvc-presentation" /><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><embed src="http://static.slideshare.net/swf/ssplayer2.swf?doc=indytechfest-2008-aspnet-mvc-published-1223261777987020-9&amp;stripped_title=indy-tech-fest-2008-aspnet-mvc-presentation" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="355"></embed></object></div>
<p>Here links to various MVC resources to get you started with ASP.NET MVC:</p>
<p>- <a href="http://www.codeplex.com/aspnet"><strong>Download ASP.NET MVC from Codeplex</strong></a>     <br />- <a href="http://mvccontrib.com/"><strong>MVCContrib – community contributions/extensions to ASP.NET MVC</strong></a>     <br />- <a href="http://codecampserver.com/"><strong>CodeCampServer – a slightly-out-of-date-but-still-good reference implementation</strong></a>     <br />- <a href="http://www.asp.net/mvc/">Official ASP.NET MVC site (lots of links to resources)</a>     <br />- <a href="http://forums.asp.net/1146.aspx">ASP.NET MVC Forums – a lot of questions asked and answers given</a>     <br />- <a href="http://weblogs.asp.net/scottgu/archive/tags/MVC/default.aspx">ScottGu’s MVC posts</a>     <br />- <a href="http://haacked.com/">Phil Haack is the ASP.NET MVC Program Manager</a>     <br />- <a href="http://weblogs.asp.net/stephenwalther/archive/tags/ASP.NET+MVC/default.aspx">Stephen Walther has done many posts on ASP.NET MVC</a>     <br />- <a href="http://technorati.com/tag/aspnetmvc">Blog posts tagged “aspnetmvc” on Technorati</a></p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=caYEFF"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=caYEFF" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=Mle5m"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=Mle5m" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=5zpvM"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=5zpvM" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=n7Ubm"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=n7Ubm" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=Hc88m"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=Hc88m" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/412513762" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/10/06/indy-tech-fest-slides/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/10/06/indy-tech-fest-slides/</feedburner:origLink></item>
		<item>
		<title>Why the iPhone Rocks</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/393729668/</link>
		<comments>http://www.aaronlerch.com/blog/2008/09/15/why-the-iphone-rocks/#comments</comments>
		<pubDate>Tue, 16 Sep 2008 01:22:47 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[iphone]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/09/15/why-the-iphone-rocks/</guid>
		<description><![CDATA[It has “save me 30 minutes” functionality baked into the platform.

Bam.
]]></description>
			<content:encoded><![CDATA[<p>It has “save me 30 minutes” functionality baked into the platform.</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iphone-my-route.jpg" /></p>
<p>Bam.</p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=YMnret"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=YMnret" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=x8sAl"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=x8sAl" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=pQbVL"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=pQbVL" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=4XTxl"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=4XTxl" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=AOCml"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=AOCml" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/393729668" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/09/15/why-the-iphone-rocks/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/09/15/why-the-iphone-rocks/</feedburner:origLink></item>
		<item>
		<title>Speaking at IndyTechFest 2008</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/392589643/</link>
		<comments>http://www.aaronlerch.com/blog/2008/09/14/speaking-at-indytechfest-2008/#comments</comments>
		<pubDate>Sun, 14 Sep 2008 20:55:32 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[community]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/09/14/speaking-at-indytechfest-2008/</guid>
		<description><![CDATA[I’m giving a talk at IndyTechFest 2008 on ASP.NET MVC. Due to the nature of the event, it’ll be more of an introduction to ASP.NET MVC than a deep dive. But we will still have fun looking at things like doing some AJAX with jQuery, etc.
Hope to see you there! The event sold out quickly, [...]]]></description>
			<content:encoded><![CDATA[<p>I’m giving a <a href="http://www.indytechfest.org/Sessions/tabid/500/Default.aspx">talk</a> at <a href="http://www.indytechfest.org/">IndyTechFest 2008</a> on ASP.NET MVC. Due to the nature of the event, it’ll be more of an introduction to ASP.NET MVC than a deep dive. But we will still have fun looking at things like doing some AJAX with jQuery, etc.</p>
<p>Hope to see you there! The event sold out quickly, but in my experience you can still get in if you show up the morning of the event. If you’re there, come over and say hi!</p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=5Q1STe"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=5Q1STe" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=QTk5l"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=QTk5l" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=YEpCL"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=YEpCL" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=ixFXl"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=ixFXl" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=hJcTl"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=hJcTl" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/392589643" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/09/14/speaking-at-indytechfest-2008/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/09/14/speaking-at-indytechfest-2008/</feedburner:origLink></item>
		<item>
		<title>Staying Sane as a Technical Manager</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/381957149/</link>
		<comments>http://www.aaronlerch.com/blog/2008/09/02/staying-sane-as-a-technical-manager/#comments</comments>
		<pubDate>Wed, 03 Sep 2008 03:33:24 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[misc]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/09/02/staying-sane-as-a-technical-manager/</guid>
		<description><![CDATA[A while ago I wrote about some characteristics of a good Technical Manager. After having some time to reflect on the transition from Developer to Technical Manager, there are three little words that I think every Technical Manager needs to take to heart.
I love you.
Oh wait, no, that was supposed to go in the email [...]]]></description>
			<content:encoded><![CDATA[<p>A while ago I wrote about some <a href="http://www.aaronlerch.com/blog/2008/04/20/from-developer-to-technical-manager/">characteristics of a good Technical Manager</a>. After having some time to reflect on the transition from Developer to Technical Manager, there are three little words that I think every Technical Manager needs to take to heart.</p>
<p>I love you.</p>
<p>Oh wait, no, that was supposed to go in the email to my wife.</p>
</p>
<p><strong>Know your limits.<img title="Drawing for ε-δ definition of limit" alt="Drawing for ε-δ definition of limit" src="http://s3.amazonaws.com:80/aaronlerch.com/images/limit.png" align="right" /></strong></p>
<p>Consider this phrase as just one aspect of the <a href="http://en.wikipedia.org/wiki/Ethic_of_reciprocity">golden rule</a> as it relates to leadership. For example, I am a person who loves to dig into details and who tends to struggle with intentionally staying at a high-level view of a project. As the team grew, we had 8 people each working on a different project. With my natural hands-on style, I found myself inadvertently ignoring half of the team, barely keeping up with the current state of their projects, while digging into the other half of the projects.</p>
<p>I realized that my current limitations were preventing me from giving attention to my co-workers and their projects that they needed, and at the same time I was growing increasingly stressed out and frustrated from trying to keep up with everybody. In the spirit of “doing to others what I would want done to me” I knew that my co-workers deserved proper attention and focus from their manager. I also knew that the more stressed I was, the less effective I was.</p>
<p>The solution in my situation? Find and/or develop another Technical Manager and split the team up, allowing each manager to provide an increased level of focus to their teams.</p>
<p>We split the teams about a month ago and the day the split went into effect I swear I felt a literal load taken off of my shoulders, and the result for both teams has been wonderful.</p>
<p>Team mitosis and optimal team size is an interesting topic that perhaps I’ll muse about more in-depth in a future post.</p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=fNKESI"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=fNKESI" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=MMkTzl"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=MMkTzl" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=z9OXTL"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=z9OXTL" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=n4eLil"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=n4eLil" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=0bp8Ml"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=0bp8Ml" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/381957149" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/09/02/staying-sane-as-a-technical-manager/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/09/02/staying-sane-as-a-technical-manager/</feedburner:origLink></item>
		<item>
		<title>A New Face for Ye Ole Blog</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/371499377/</link>
		<comments>http://www.aaronlerch.com/blog/2008/08/21/a-new-face-for-ye-ole-blog/#comments</comments>
		<pubDate>Thu, 21 Aug 2008 23:23:02 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[blogging]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/?p=180</guid>
		<description><![CDATA[I&#8217;ve moved my blog to a new host (sounds very science fiction-y, eh?) and with it comes a new look and feel. What do you think? Maybe you&#8217;d prefer new content? Yeah, me too&#8230; 
]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve moved my blog to a new host (sounds very science fiction-y, eh?) and with it comes a new look and feel. What do you think? Maybe you&#8217;d prefer new content? Yeah, me too&#8230; <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /></p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=LaLZtb"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=LaLZtb" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=YISDok"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=YISDok" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=S2n84K"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=S2n84K" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=RnZC6k"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=RnZC6k" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=tFpUuk"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=tFpUuk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/371499377" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/08/21/a-new-face-for-ye-ole-blog/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/08/21/a-new-face-for-ye-ole-blog/</feedburner:origLink></item>
		<item>
		<title>Rock the iPhone with ASP.NET MVC</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/307727158/</link>
		<comments>http://www.aaronlerch.com/blog/2008/06/08/rock-the-iphone-with-aspnet-mvc/#comments</comments>
		<pubDate>Sun, 08 Jun 2008 23:30:06 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[asp.net]]></category>

		<category><![CDATA[asp.net mvc]]></category>

		<category><![CDATA[iphone]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/06/08/rock-the-iphone-with-aspnet-mvc/</guid>
		<description><![CDATA[With much fanfare Apple announced the availability of the iPhone SDK. I downloaded it and someday plan to play around with it, though with the SDK already having gone through 4 or 5 beta releases (each a ~2GB download) I’ll probably wait a long time before cracking it open. However, for web applications the best [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iphone1.png" align="right" />With much fanfare Apple announced the availability of the <a href="http://developer.apple.com/iphone/">iPhone SDK</a>. I downloaded it and someday plan to play around with it, though with the SDK already having gone through 4 or 5 beta releases (each a ~2GB download) I’ll probably wait a long time before cracking it open. However, for web applications <em>the best way to integrate with an iPhone is still through the browser</em>.</p>
<p>Unfortunately Apple didn&#8217;t provide much help in the form of html or css to make your website &#8220;iPhone-y&#8221;. They <a href="http://developer.apple.com/webapps/">provide</a> documentation on elements like iPhone specific events (&#8221;onorientationchange&#8221;) and details about how Safari works on the iPhone in terms of zooming, etc., but nothing that offers guidance on how to make an application look like it belongs on the iPhone.</p>
<p>Enter <a href="http://joehewitt.com/">Joe Hewitt</a> and <a href="http://code.google.com/p/iui/">iUI</a>. iUI takes HTML that follows a simple set of conventions and does all the heavy lifting to enable you to easily build a version of your site that is tailored for the iPhone experience. I <a href="http://www.aaronlerch.com/blog/2007/10/27/writing-web-apps-for-the-iphone/">first started using iUI</a> before ASP.NET MVC was publicly introduced, and I specifically remember thinking how much iUI was built for &#8220;<a href="http://www.hanselman.com/blog/ASPNETMVCWebFormsUnplugged.aspx">webforms unplugged</a>&#8220;. Let&#8217;s take a quick look at an example of how iUI works, and how to use it with ASP.NET MVC.</p>
<p>If you’re the type that likes to get their hands dirty first, <a href="http://s3.amazonaws.com:80/aaronlerch.com/files/iUISample.v1.zip">download the code here</a>.</p>
<h1>CSS Zen Garden</h1>
<p>iUI is literally nothing more than some javascript, some css, and a bunch of image assets. It’s how things are supposed to work with HTML and it’s beautiful, like the <a href="http://www.csszengarden.com/">CSS Zen Garden</a>. It also has some simple conventions that I’ll summarize like so: “write HTML the way it was intended”. &lt;ul&gt; or &lt;ol&gt; for lists, and &lt;div&gt; or &lt;form&gt; for dialogs and pages. Easy enough, right? There’s not a ton to iUI but for this post I’ll start simple. Let’s create a list of products that we want to display like so:</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iui-product_list_screenshot.png" /></p>
<p>This is the HTML behind the list itself (not including the top toolbar, though the “title” attribute of the list controls the text shown in the center of the toolbar):</p>
<pre class="csharpcode"><span class="kwrd">&lt;</span><span class="html">ul</span> <span class="attr">id</span><span class="kwrd">="products"</span> <span class="attr">title</span><span class="kwrd">="Products"</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/1"</span><span class="kwrd">&gt;</span>Alice Mutton<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/2"</span><span class="kwrd">&gt;</span>Aniseed Syrup<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/3"</span><span class="kwrd">&gt;</span>Boston Crab Meat<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/4"</span><span class="kwrd">&gt;</span>Camembert Pierrot<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/5"</span><span class="kwrd">&gt;</span>Carnarvon Tigers<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/6"</span><span class="kwrd">&gt;</span>Chai<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/7"</span><span class="kwrd">&gt;</span>Chang<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/8"</span><span class="kwrd">&gt;</span>Chartreuse verte<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;/</span><span class="html">ul</span><span class="kwrd">&gt;</span></pre>
<style type="text/css">.csharpcode, .csharpcode pre { 	font-size: small; 	color: black; 	font-family: consolas, "Courier New", courier, monospace; 	background-color: #ffffff; 	/*white-space: pre;*/ } .csharpcode pre { margin: 0em; } .csharpcode .rem { color: #008000; } .csharpcode .kwrd { color: #0000ff; } .csharpcode .str { color: #006080; } .csharpcode .op { color: #0000c0; } .csharpcode .preproc { color: #cc6633; } .csharpcode .asp { background-color: #ffff00; } .csharpcode .html { color: #800000; } .csharpcode .attr { color: #ff0000; } .csharpcode .alt  { 	background-color: #f4f4f4; 	width: 100%; 	margin: 0em; } .csharpcode .lnum { color: #606060; }</style>
<p>iUI does the heavy lifting to format the list in the iPhone style, and will dynamically load any linked content using an AJAX call and render it in-place, replacing the current list (“products”). iUI handles sliding in the new content from the right-hand side, just like a native iPhone application.</p>
<p>You could also reference another list defined within the same page, for example if you had a very short list of items and had each list item’s “linked content” also included in the page, like this:</p>
<pre class="csharpcode"><span class="kwrd">&lt;</span><span class="html">ul</span> <span class="attr">id</span><span class="kwrd">="products"</span> <span class="attr">title</span><span class="kwrd">="Products"</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="#subproduct1"</span><span class="kwrd">&gt;</span>Product 1<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;/</span><span class="html">ul</span><span class="kwrd">&gt;</span>

<span class="kwrd">&lt;</span><span class="html">ul</span> <span class="attr">id</span><span class="kwrd">="subproduct1"</span> <span class="attr">title</span><span class="kwrd">="Related Products"</span><span class="kwrd">&gt;</span>
   <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;</span>Sub Item 1<span class="kwrd">&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
   <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;</span>Sub Item 2<span class="kwrd">&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;/</span><span class="html">ul</span><span class="kwrd">&gt;</span></pre>
<style type="text/css">.csharpcode, .csharpcode pre { 	font-size: small; 	color: black; 	font-family: consolas, "Courier New", courier, monospace; 	background-color: #ffffff; 	/*white-space: pre;*/ } .csharpcode pre { margin: 0em; } .csharpcode .rem { color: #008000; } .csharpcode .kwrd { color: #0000ff; } .csharpcode .str { color: #006080; } .csharpcode .op { color: #0000c0; } .csharpcode .preproc { color: #cc6633; } .csharpcode .asp { background-color: #ffff00; } .csharpcode .html { color: #800000; } .csharpcode .attr { color: #ff0000; } .csharpcode .alt  { 	background-color: #f4f4f4; 	width: 100%; 	margin: 0em; } .csharpcode .lnum { color: #606060; }</style>
<h1>The Root Page</h1>
<p>iUI will dynamically render partial content into the current view, but it needs an initial root page describing the main layout. The easiest way to figure out what is needed is to look at one of the examples that iUI includes, but in a nutshell you’ll probably need at least two elements: the toolbar (the heading) and some content. To support the example above of a product list, our entire root page could look like this:</p>
<pre class="csharpcode"><span class="kwrd">&lt;!</span><span class="html">DOCTYPE</span> <span class="attr">html</span> <span class="attr">PUBLIC</span> <span class="kwrd">"-//W3C//DTD XHTML 1.0 Strict//EN"</span> <span class="kwrd">"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;</span><span class="html">html</span> <span class="attr">xmlns</span><span class="kwrd">="http://www.w3.org/1999/xhtml"</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;</span><span class="html">head</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">meta</span> <span class="attr">http-equiv</span><span class="kwrd">="Content-Type"</span> <span class="attr">content</span><span class="kwrd">="text/html; charset=iso-8859-1"</span> <span class="kwrd">/&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">title</span><span class="kwrd">&gt;</span>Northwind Explorer<span class="kwrd">&lt;/</span><span class="html">title</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">meta</span> <span class="attr">name</span><span class="kwrd">="viewport"</span> <span class="attr">content</span><span class="kwrd">="width=320; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;"</span><span class="kwrd">/&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">style</span> <span class="attr">type</span><span class="kwrd">="text/css"</span> <span class="attr">media</span><span class="kwrd">="screen"</span><span class="kwrd">&gt;</span>@import "../../Content/iui/iui.css";<span class="kwrd">&lt;/</span><span class="html">style</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">script</span> <span class="attr">type</span><span class="kwrd">="application/x-javascript"</span> <span class="attr">src</span><span class="kwrd">="../../Content/iui/iui.js"</span><span class="kwrd">&gt;&lt;/</span><span class="html">script</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;/</span><span class="html">head</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;</span><span class="html">body</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">div</span> <span class="attr">class</span><span class="kwrd">="toolbar"</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">h1</span> <span class="attr">id</span><span class="kwrd">="pageTitle"</span><span class="kwrd">&gt;&lt;/</span><span class="html">h1</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">a</span> <span class="attr">id</span><span class="kwrd">="backButton"</span> <span class="attr">class</span><span class="kwrd">="button"</span> <span class="attr">href</span><span class="kwrd">="#"</span><span class="kwrd">&gt;&lt;/</span><span class="html">a</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;/</span><span class="html">div</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;</span><span class="html">ul</span> <span class="attr">id</span><span class="kwrd">="products"</span> <span class="attr">title</span><span class="kwrd">="Products"</span> <span class="attr">selected</span><span class="kwrd">="true"</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/1"</span><span class="kwrd">&gt;</span>Alice Mutton<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/2"</span><span class="kwrd">&gt;</span>Aniseed Syrup<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/3"</span><span class="kwrd">&gt;</span>Boston Crab Meat<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/4"</span><span class="kwrd">&gt;</span>Camembert Pierrot<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/5"</span><span class="kwrd">&gt;</span>Carnarvon Tigers<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/6"</span><span class="kwrd">&gt;</span>Chai<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/7"</span><span class="kwrd">&gt;</span>Chang<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
        <span class="kwrd">&lt;</span><span class="html">li</span><span class="kwrd">&gt;&lt;</span><span class="html">a</span> <span class="attr">href</span><span class="kwrd">="/products/index/8"</span><span class="kwrd">&gt;</span>Chartreuse verte<span class="kwrd">&lt;/</span><span class="html">a</span><span class="kwrd">&gt;&lt;/</span><span class="html">li</span><span class="kwrd">&gt;</span>
    <span class="kwrd">&lt;/</span><span class="html">ul</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;/</span><span class="html">body</span><span class="kwrd">&gt;</span>
<span class="kwrd">&lt;/</span><span class="html">html</span><span class="kwrd">&gt;</span></pre>
<style type="text/css">.csharpcode, .csharpcode pre { 	font-size: small; 	color: black; 	font-family: consolas, "Courier New", courier, monospace; 	background-color: #ffffff; 	/*white-space: pre;*/ } .csharpcode pre { margin: 0em; } .csharpcode .rem { color: #008000; } .csharpcode .kwrd { color: #0000ff; } .csharpcode .str { color: #006080; } .csharpcode .op { color: #0000c0; } .csharpcode .preproc { color: #cc6633; } .csharpcode .asp { background-color: #ffff00; } .csharpcode .html { color: #800000; } .csharpcode .attr { color: #ff0000; } .csharpcode .alt  { 	background-color: #f4f4f4; 	width: 100%; 	margin: 0em; } .csharpcode .lnum { color: #606060; }</style>
<p>The site will initially show the list of products, and when the user clicks on a product, the &lt;ul id=”products” title=”Products” selected=”true”&gt;…&lt;/ul&gt; element will be wholesale replaced with the content loaded by an AJAX call to “/products/index/[number]”.</p>
<h1>Hooking up iUI to MVC</h1>
<p>First things first - <a href="http://code.google.com/p/iui/source/browse/trunk/iui">download</a> the latest iUI assets from the google code repository trunk. You&#8217;ll get the latest bug fixes and features, which I&#8217;ve found to be helpful. As a side note, you can view some samples directly from the repository itself - like the <a href="http://iui.googlecode.com/svn/trunk/samples/music.html">music example</a>. Put the downloaded files in the Content directory:</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iui-assets.png" /></p>
<p>Define your main page—the main entry point to the site. I chose /home/index in my example. This is where you’ll reference the iUI javascript and css assets, and define the initial structure of your page.</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iui-products_home.png" /></p>
<p>One big catch that I already mentioned with iUI is that it expects links (whether AJAX-loaded or in-page references) to return HTML fragments. It literally takes the results of an AJAX call to a given URL and sets the innerHTML of the content to replace.</p>
<p>This means that every other page in our application should return partial content. For example, when I click on “Products” this is the only content of the view page that lists the products:</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iui-product_list.png" /></p>
<p>As you can see, it’s simply building the list itself and rendering the partial HTML content as a response.</p>
<p>You can connect with an iPhone on your local network with a wifi connection, but it’s much easier to install and test with <a href="http://www.apple.com/safari/">Safari for Windows</a>. Both Safari for Windows and the iPhone’s mobile Safari use the <a href="http://webkit.org/">WebKit</a> engine so the rendering experience is about as close as you can get. Shrink the browser to approximately the size of the iPhone screen and you’d never know you didn’t spend the $400+ on an iPhone. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /><br />
<img src="http://s3.amazonaws.com:80/aaronlerch.com/images/iui-safari.png" /></p>
<p>You can <a href="http://s3.amazonaws.com:80/aaronlerch.com/files/iUISample.v1.zip">download the first version of my example project here</a>.</p>
<h1>Up Next</h1>
<p>In future posts I’ll explore some more of iUI’s features such as adding a product page to view details of a product in a friendly way (I’ve included this in the example project already), rendering partial lists (allowing the user to expand the list incrementally), detecting the user agent and loading iPhone views vs. “normal” views, and more. I’ll update the example project as we go!</p>
<p><a href="http://www.dotnetkicks.com/kick/?url=http://www.aaronlerch.com/blog/2008/06/08/rock-the-iphone-with-aspnet-mvc/"><img src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http://www.aaronlerch.com/blog/2008/06/08/rock-the-iphone-with-aspnet-mvc/" border="0" alt="kick it on DotNetKicks.com" /></a></p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=iIDNPC"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=iIDNPC" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=qPyIGi"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=qPyIGi" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=Mv7n7I"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=Mv7n7I" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=JhAJBi"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=JhAJBi" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=FGK4oi"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=FGK4oi" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/307727158" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/06/08/rock-the-iphone-with-aspnet-mvc/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/06/08/rock-the-iphone-with-aspnet-mvc/</feedburner:origLink></item>
		<item>
		<title>Off to TechEd 2008</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/302455944/</link>
		<comments>http://www.aaronlerch.com/blog/2008/06/01/off-to-teched-2008/#comments</comments>
		<pubDate>Sun, 01 Jun 2008 17:27:05 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[community]]></category>

		<category><![CDATA[microsoft]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/06/01/off-to-teched-2008/</guid>
		<description><![CDATA[I&#8217;m leaving tomorrow for TechEd 2008 in Orlando, FL. I&#8217;m excited about it since it&#8217;s my first developer conference that isn&#8217;t targeted at a very specific purpose (like Interact 2008 was). I&#8217;m looking forward to attending some good sessions, meeting some people I&#8217;ve only ever e-listened to, and spending some relaxing evenings with my wife [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m leaving tomorrow for TechEd 2008 in Orlando, FL. I&#8217;m excited about it since it&#8217;s my first developer conference that isn&#8217;t targeted at a very specific purpose (like <a href="http://www.interact08.com/">Interact 2008</a> was). I&#8217;m looking forward to attending some good sessions, meeting some people I&#8217;ve only ever e-listened to, and spending some relaxing evenings with my wife who&#8217;s coming with to enjoy a little R&amp;R away from the <a href="http://picasaweb.google.com/aaronlerch/Kiddos">kids</a>.</p>
<p>Unfortunately, we&#8217;ve been <a href="http://www.indystar.com/apps/pbcs.dll/article?AID=/20080601/LOCAL18/806010402">without power</a> at our home since 10PM last Friday night due to storms and tornados. Not only is the power out in our area of the city, but a big tree fell on our specific power lines, ripping everything away from the house. So the weekend has been spent calling utility companies, contractors, waiting, and <a href="http://www.goodreads.com/review/list/92438">reading</a>. Our family lives far away, so we&#8217;ve really appreciated our friends who have welcomed us into their homes, shared their meals with us, and let us type blog posts from their laptops. <img src='http://www.aaronlerch.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> (Thanks Shawn!)</p>
<p>If you&#8217;re going to TechEd and want to meet up, drop me an email at aaronlerch at gmail or <a href="http://twitter.com/aaronlerch">tweet me on twitter</a>. I&#8217;ll be at <a href="http://teched2008.partywithpalermo.com/">Party with Palermo</a> on Monday night.</p>
<p>See you in Orlando!</p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=Nt9j3k"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=Nt9j3k" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=qkZZJi"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=qkZZJi" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=zIr0XI"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=zIr0XI" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=kbFboi"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=kbFboi" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=AtFzxi"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=AtFzxi" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/302455944" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/06/01/off-to-teched-2008/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/06/01/off-to-teched-2008/</feedburner:origLink></item>
		<item>
		<title>First thoughts on ASP.NET MVC Preview 3</title>
		<link>http://feeds.feedburner.com/~r/aaronlerch/~3/299517139/</link>
		<comments>http://www.aaronlerch.com/blog/2008/05/27/first-thoughts-on-aspnet-mvc-preview-3/#comments</comments>
		<pubDate>Wed, 28 May 2008 02:57:11 +0000</pubDate>
		<dc:creator>aaron</dc:creator>
		
		<category><![CDATA[asp.net mvc]]></category>

		<guid isPermaLink="false">http://www.aaronlerch.com/blog/2008/05/27/first-thoughts-on-aspnet-mvc-preview-3/</guid>
		<description><![CDATA[I had a chance to play with the latest ASP.NET MVC drop tonight. There&#8217;s a few changes (some of which came in Preview 2) but a few items caught my eye fairly quickly.
ActionResult
This change came with Preview 2, but it&#8217;s worth mentioning. Instead of controller actions returning void, they now return an ActionResult instance. This [...]]]></description>
			<content:encoded><![CDATA[<p>I had a chance to play with the latest <a href="http://www.asp.net/mvc/">ASP.NET MVC</a> drop tonight. There&#8217;s a few changes (<a href="http://flux88.com/ASPNETMVCPreview2Update.aspx">some of which came in Preview 2</a>) but a few items caught my eye fairly quickly.</p>
<p><strong>ActionResult</strong></p>
<p>This change came with Preview 2, but it&#8217;s worth mentioning. Instead of controller actions returning void, they now return an ActionResult instance. This increases testability and separates functionality. Testability because now controllers can be tested without mocking out all the requirements for invoking the view, and functionality because the loading and invoking of an action&#8217;s view is encapsulated in a class structure apart from the controllers.</p>
<p><strong>JsonResult</strong></p>
<p>Something that is included new in Preview 3 is JsonResult (a subclass of ActionResult). It looks like some of <a href="http://www.aaronlerch.com/blog/2008/01/01/unifying-web-sites-and-web-services-with-the-aspnet-mvc-framework/">my crazy ideas</a> weren&#8217;t so crazy after all? A new method on the controller, &quot;Json()&quot;, takes a serializable object and returns a JsonResult which uses the obsoleted (whoops??) JavaScriptSerializer to render the object as JSON.</p>
<p>So a controller&#8217;s action could look like this:</p>
<p><img src="http://s3.amazonaws.com:80/aaronlerch.com/images/controller-json-1.png" /></p>
<p><strong>RedirectToRoute</strong></p>
<p>If a controller action needed to redirect, our only option (until now) has been RedirectToAction which accepts an action name and optional controller name. That&#8217;s not bad, but now we have RedirectToRoute which allows us to redirect to a named route, making things more flexible and easier to change (without mass <a href="http://www.aaronlerch.com/blog/2007/03/28/visual-studio-find-and-replace-regular-expressions/">find/replacing</a> all over the place).</p>
<p><strong>And more&#8230;</strong></p>
<p>Scott Guthrie has <a href="http://weblogs.asp.net/scottgu/archive/2008/05/27/asp-net-mvc-preview-3-release.aspx">more details</a>, and Scott Hanselman (so many Scotts!) has a few <a href="http://www.hanselman.com/blog/ASPNETMVCPreview3.aspx">updated screencasts</a>. Be sure to check them out.</p>
<p>Things with MVC are solidifying and starting to look pretty good. Check out the <a href="http://mvccontrib.org/">MvcContrib</a> or <a href="http://code.google.com/p/codecampserver/">CodeCampServer</a> projects for some decent reference implementations.</p>

<p><a href="http://feeds.feedburner.com/~a/aaronlerch?a=HNsYLK"><img src="http://feeds.feedburner.com/~a/aaronlerch?i=HNsYLK" border="0"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/aaronlerch?a=QmP86h"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=QmP86h" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=JWJe7H"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=JWJe7H" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=XOQC5h"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=XOQC5h" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/aaronlerch?a=xvYLah"><img src="http://feeds.feedburner.com/~f/aaronlerch?i=xvYLah" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/aaronlerch/~4/299517139" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.aaronlerch.com/blog/2008/05/27/first-thoughts-on-aspnet-mvc-preview-3/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.aaronlerch.com/blog/2008/05/27/first-thoughts-on-aspnet-mvc-preview-3/</feedburner:origLink></item>
	</channel>
</rss>
