<?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/"
	>

<channel>
	<title>Software Rockstar &#187; ASP.NET</title>
	<atom:link href="http://www.softwarerockstar.com/tag/aspnet/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.softwarerockstar.com</link>
	<description>Coaching and mentoring on a journey from a Developer to an IT Leader</description>
	<lastBuildDate>Thu, 12 Nov 2009 18:12:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>SubSonic 3.0 Released</title>
		<link>http://www.softwarerockstar.com/2009/07/subsonic-30-released/</link>
		<comments>http://www.softwarerockstar.com/2009/07/subsonic-30-released/#comments</comments>
		<pubDate>Sat, 04 Jul 2009 18:52:15 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[ASP.NET MVC]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[Cool Tools]]></category>
		<category><![CDATA[SubSonic]]></category>

		<guid isPermaLink="false">http://www.softwarerockstar.com/?p=486</guid>
		<description><![CDATA[Finally a new version of SubSonic was released today with a lot of new features.  SubSonic is one of my favorite Data Access Layer (DAL) generators, that makes it super easy to create data access code. As a developer you have a lot of control over what the generated code looks like, which is great [...]]]></description>
			<content:encoded><![CDATA[<div class="imageleft"><img class="alignnone size-medium wp-image-487" src="http://softwarerockstar.com/wp-content/uploads/2009/07/subsonic_demo-300x191.png" alt="Subsonic Demo" width="300" height="191" /></div>
<p>Finally a new version of SubSonic was released today with a lot of new features.  SubSonic is one of my favorite Data Access Layer (DAL) generators, that makes it super easy to create data access code.</p>
<p>As a developer you have a lot of control over what the generated code looks like, which is great because I do not like code generators to dictate the essence of my code.  But the beauty of SubSonic is that you never really have to interact with the generated code itself.  It&#8217;s automatically generated and compiled for you &#8212; you just need to learn how to use it, which is pretty simple.  What&#8217;s more, it&#8217;s free, and works with not only SQL Server, but also with MySQL, SQLite, and Oracle databases. <span id="more-486"></span></p>
<p>SubSonic was originally started by Rob Conery as an open source project.  Later, Microsoft hired Rob and asked him to continue working on this project.  The latest 3.0 version took about a year to be completed.  According to Rob&#8217;s blog following are some of the new features:</p>
<blockquote>
<li>A nice <a href="http://subsonicproject.com/docs/IQueryable">Linq engine</a> which parses IQueryable &#8220;stuff&#8221; into SQL (thanks to <a href="http://blogs.msdn.com/mattwar/">Matt Warren&#8217;s</a> excellent  work with the <a href="http://codeplex.com/iqtoolkit">IQToolkit</a>, which we stole mercilessly).</li>
<li>A <a href="http://subsonicproject.com/docs/T4_Templates">templating system</a> which allows you to use <a href="http://subsonicproject.com/docs/Using_ActiveRecord">ActiveRecord</a>, <a href="http://subsonicproject.com/docs/Using_AdvancedTemplates">good  old Linq in Linq to SQL style</a>, or <a href="http://subsonicproject.com/docs/Creating_Your_Own_DAL">whatever floats your boat</a>.</li>
<li>A <a href="http://subsonicproject.com/docs/Using_SimpleRepository">SimpleRepository</a> which is just about zero-drag and even builds  your database for you</li>
<li>A brand-new <a href="http://subsonicproject.com/">project  site</a> that will hopefully answer the question &#8220;is SubSonic dead&#8221;? Or probably  not</li>
<li>A <a href="http://subsonicproject.com/docs">new docs site</a> that has  permanently crushed my ability to type. It&#8217;s a wiki so if you feel like being  helpful and like SubSonic and want to help&#8230; nudge&#8230; nudge</li>
</blockquote>
<div>
<p>If you have never used SubSonic before you owe it to yourself to check out this <a href="http://subsonicproject.com/docs/The_5_Minute_Demo" target="_blank">5-minute demo</a>.</div>
<div>
<p>You can get more information on SubSonic and download it for free at the <a href="http://subsonicproject.com/" target="_blank">SubSonic project site</a>.</div>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2009/07/subsonic-30-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Learn ASP.NET MVC</title>
		<link>http://www.softwarerockstar.com/2009/03/learn-aps-net-mvc/</link>
		<comments>http://www.softwarerockstar.com/2009/03/learn-aps-net-mvc/#comments</comments>
		<pubDate>Sat, 14 Mar 2009 05:38:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[Architecture]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2009/03/13/learn-aps-net-mvc/</guid>
		<description><![CDATA[ScottGu  just made available a free downloadable eBook in PDF format as well as a simple and easy-to-understand sample project called Nerddinner. The eBook is actually a chapter from his upcoming book on MVC, but it is an end-to-end tutorial that walks through building a small but complete ASP.NET MVC application from scratch. Download eBook. [...]]]></description>
			<content:encoded><![CDATA[<div class="imageleft"><a href="http://www.amazon.com/gp/product/0470384611?ie=UTF8&amp;tag=softwrocks-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0470384611"><img style="border: 0px;" src="http://ecx.images-amazon.com/images/I/41vsFoLZq9L._BO2,204,203,200_PIsitb-sticker-arrow-big-search,TopRight,35,-76_AA240_SH20_OU01_.jpg" border="0" alt="" width="216" height="216" /></a><img style="border:none !important; margin:0px !important;" src="http://www.assoc-amazon.com/e/ir?t=softwrocks-20&amp;l=as2&amp;o=1&amp;a=0470384611" border="0" alt="" width="1" height="1" /></div>
<p>ScottGu  just made available a free downloadable eBook in PDF format as well as a simple and easy-to-understand sample project called Nerddinner.</p>
<p>The eBook is actually a chapter from his upcoming book on MVC, but it is an end-to-end tutorial that walks through building a small but complete ASP.NET MVC application from scratch.</p>
<p><a href="http://aspnetmvcbook.s3.amazonaws.com/aspnetmvc-nerdinner_v1.pdf" target="_blank">Download eBook</a>.</p>
<p><a href="http://nerddinner.codeplex.com/" target="_blank">Download Nerddinner sample code</a>.</p>
<p><a href="http://www.amazon.com/gp/product/0470384611?ie=UTF8&amp;tag=softwrocks-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0470384611">Buy ASP.NET MVC 1.0 Book at Amazon.com</a>. </p>
<p>If you do decide to read this book, please do not forget to share your thoughts with me.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2009/03/learn-aps-net-mvc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Astoria and Jasper: Old Ideas New Technology</title>
		<link>http://www.softwarerockstar.com/2007/10/astoria-and-jasper-old-ideas-new-technology/</link>
		<comments>http://www.softwarerockstar.com/2007/10/astoria-and-jasper-old-ideas-new-technology/#comments</comments>
		<pubDate>Fri, 19 Oct 2007 01:19:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Other]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ADO.NET]]></category>
		<category><![CDATA[Agile]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Cool Tools]]></category>
		<category><![CDATA[Silverlight]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2007/10/18/astoria-and-jasper-old-ideas-new-technology/</guid>
		<description><![CDATA[SubSonic is an excellent open source DAL generation tool developed by Rob Conery that has been around for almost a year. In most cases SubSonic can just be added to your project, pointed to a databse, and you magically and immediately gain access to a rich and strongly typed object model that can be used [...]]]></description>
			<content:encoded><![CDATA[<div class="imageleft"><img src="http://softwarerockstar.com/wp-content/uploads/2007/10/dotnet.png" alt="Microsoft .NET" title="Microsoft .NET" width="189" height="100" /></div>
<p><a href="http://www.subsonicproject.com/">SubSonic</a> is an excellent open source <a href="http://en.wikipedia.org/wiki/Data_access_layer">DAL</a> generation tool developed by Rob Conery that has been around for almost a year. In most cases <a href="http://www.subsonicproject.com/">SubSonic</a> can just be added to your project, pointed to a databse, and you magically and immediately gain access to a rich and strongly typed object model that can be used to query and persist data to and from your relational data source.</p>
<p><a href="http://www.subsonicproject.com/">SubSonic</a> also has a cool feature called the <a href="http://en.wikipedia.org/wiki/REST">REST</a> handler that essentially allows one to use <a href="http://en.wikipedia.org/wiki/Http">HTTP</a> protocol as an interface to data stored in a back-end relational database. It is <a href="http://en.wikipedia.org/wiki/Uniform_Resource_Identifier">URI</a> based and returns data back in <a href="http://en.wikipedia.org/wiki/Xml">XML</a> format. This data can then be used by decoupled client applications as they see fit. If you have never looked at <a href="http://www.subsonicproject.com/">SubSonic</a>, you owe it to yourself to checkout this very cool tool.</p>
<p>Recently Microsoft unveiled their plans to release similar features codenamed <a href="http://astoria.mslivelabs.com/">Astoria</a> and <a href="http://msdn2.microsoft.com/en-us/data/bb419139.aspx">Jasper</a> with <a href="http://msdn2.microsoft.com/en-us/vstudio/aa700831.aspx">.NET framework 3.5 and Visual Studio 2008</a>. The CTP of <a href="http://astoria.mslivelabs.com/">Astoria</a> and <a href="http://msdn2.microsoft.com/en-us/data/bb419139.aspx">Jasper</a> are available for download from Microsoft.</p>
<p>Jasper is described by Microsoft as:</p>
<blockquote><p>Project Jasper is geared towards iterative and agile development. You can<br />
start interacting with the data in your database without having to create<br />
mapping files or define classes. You can build user interfaces by naming<br />
controls according to your model without worrying about binding code. Project<br />
Jasper is also extensible, allowing you to provide your own business logic and<br />
class model. Since Project Jasper is built on top of the ADO.NET Entity<br />
Framework, it supports rich queries and complex mapping.
</p></blockquote>
<p>Pablo Castro, the mastermind behind Astoria describes it as:</p>
<blockquote><p>The goal of Microsoft Codename Astoria is to enable applications to expose data as a data service that can be consumed by web clients within a corporate network and across the internet. The data service is reachable over HTTP, and URIs are used to identify the various pieces of information available through the service. Interactions with the data service happens in terms of HTTP verbs such as GET, POST, PUT and DELETE, and the data exchanged in those interactions is represented in simple formats such as XML and JSON.</p></blockquote>
<p>The <a href="http://astoria.mslivelabs.com/">Astoria</a> web site also includes <a href="http://astoria.mslivelabs.com/OnlineService.aspx">sample online services</a> that showcases how this new technology can be used. It also allows anyone with a Passport account to design and host their own experimental data services .</p>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2007/10/astoria-and-jasper-old-ideas-new-technology/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Temporary ASP.NET Files</title>
		<link>http://www.softwarerockstar.com/2007/05/temporary-asp-net-files/</link>
		<comments>http://www.softwarerockstar.com/2007/05/temporary-asp-net-files/#comments</comments>
		<pubDate>Tue, 22 May 2007 18:55:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2007/05/22/temporary-asp-net-files/</guid>
		<description><![CDATA[ASP.NET generates temporary files from the code-behind and aspx files that it compiles into assemblies behind the scenes. These temporary files are stored in %WINDIR%\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files folder. Sometimes these files get out-of-sync with the user code and modifications to the code have no effect while debugging. In such situations it is safe to delete [...]]]></description>
			<content:encoded><![CDATA[<div class="imageleft"><img src="http://softwarerockstar.com/wp-content/uploads/2009/03/vs2008.png" alt="Visual Studio Image" width="199" height="122" /></div>
<p><a href="http://www.asp.net/">ASP.NET</a> generates temporary files from the code-behind and aspx files that it compiles into assemblies behind the scenes.  These temporary files are stored in %WINDIR%\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files folder.  Sometimes these files get out-of-sync with the user code and modifications to the code have no effect while debugging.  In such situations it is safe to delete the contents of this folder and force ASP.NET to regenerate these files.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2007/05/temporary-asp-net-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Anthem.NET &#8211; An AJAX Library for ASP.NET</title>
		<link>http://www.softwarerockstar.com/2006/12/anthem-net-an-ajax-library-for-asp-net/</link>
		<comments>http://www.softwarerockstar.com/2006/12/anthem-net-an-ajax-library-for-asp-net/#comments</comments>
		<pubDate>Thu, 07 Dec 2006 17:02:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Cool Tools]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2006/12/07/anthem-net-an-ajax-library-for-asp-net/</guid>
		<description><![CDATA[A coworker introduced me to Anthem.NET, which is an AJAX library for the ASP.NET platform. Within the last year or so, quite a few AJAX libraries have surfaced, including Microsoft&#8217;s ASP.NET AJAX (formerly known as ATLAS), and other free and commercial products. Some of these are pretty decent, while others are not even worth investigating. Anthem.NET, [...]]]></description>
			<content:encoded><![CDATA[<p>A coworker introduced me to <a href="http://anthemdotnet.com">Anthem.NET</a>, which is an <a href="http://en.wikipedia.org/wiki/Ajax_(programming)">AJAX </a>library for the <a href="http://en.wikipedia.org/wiki/ASP.NET">ASP.NET</a> platform. Within the last year or so, quite a few AJAX libraries have surfaced, including Microsoft&#8217;s <a href="http://ajax.asp.net/Default.aspx">ASP.NET AJAX</a> (formerly known as ATLAS), and other free and commercial products. Some of these are pretty decent, while others are not even worth investigating. Anthem.NET, with it&#8217;s impressive functionality, belongs to the former group.</p>
<p>Some of the features of Anthem.NET include:</p>
<ul>
<li>Free and open source</li>
<li>Support for .NET 1.x and 2.0</li>
<li>Seamless integration with Visual Studio 2005</li>
<li>Broad browser support (IE, Firefox, and Safari)</li>
<li>Support for Mono</li>
<li>Familiar ASP.NET postback style functionality</li>
<li>Support for ASP.NET ViewState</li>
<li>Support for web user controls</li>
</ul>
<p>You can download Anthem.NET from <a href="http://anthem-dot-net.sourceforge.net/">SourceForge</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2006/12/anthem-net-an-ajax-library-for-asp-net/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>.NET 2.0: On-demand Configuration Encryption</title>
		<link>http://www.softwarerockstar.com/2006/10/net-2-0-on-demand-configuration-encryption/</link>
		<comments>http://www.softwarerockstar.com/2006/10/net-2-0-on-demand-configuration-encryption/#comments</comments>
		<pubDate>Mon, 02 Oct 2006 17:09:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[WinForms]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2006/10/02/net-2-0-on-demand-configuration-encryption/</guid>
		<description><![CDATA[In .NET 2.0, apsnet_regiis can encrypt and decrypt sections of web.config and machine.config using RSA, DPAPI, or any other custom encryption provider. However, how do we encrypt/decrypt a custom application configuration (e.g. app.config of a WinForms application)? We are in luck, since the System.Configuration namespace provides everything we need to accomplish this task. The following [...]]]></description>
			<content:encoded><![CDATA[<div class="imageleft"><img src="http://softwarerockstar.com/wp-content/uploads/2006/10/encryption1.jpg" alt="Binary Code" width="300" height="244" class="alignnone size-full wp-image-325" /></div>
<p>In .NET 2.0, <a href="http://msdn2.microsoft.com/en-us/library/k6h9cz8h.aspx">apsnet_regiis</a> can encrypt and decrypt sections of web.config and machine.config using <a href="http://www.rsasecurity.com/">RSA</a>, <a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnsecure/html/windataprotection-dpapi.asp">DPAPI</a>, or any other custom encryption provider. However, how do we encrypt/decrypt a custom application configuration (e.g. app.config of a WinForms application)?</p>
<p>We are in luck, since the <a href="http://msdn2.microsoft.com/en-us/library/system.configuration.aspx">System.Configuration </a>namespace provides everything we need to accomplish this task. The following class, for example, can be used to encrypt/decrypt any .NET configuration file:</p>
<pre class="brush: csharp">
///
/// Implements a utility class that enables encrypting / decrypting
/// sections in .NET configuration files.
///
internal static class ConfigEncryptionHelper
{
    #region Encryption Methods

    ///
    /// Encrypts a section in a .NET configuration file using a named provider.
    ///
    /// Physical path of configuration file.
    /// Section name to encrypt.
    /// Name of the encryption provider.
    public static void EncryptConfigSection(string configPath, string sectionName, string protectionProviderName)
    {
        // Map the configuration file
        ExeConfigurationFileMap fileMap = new ExeConfigurationFileMap();
        fileMap.ExeConfigFilename = configPath;

        // Open configuration file
        Configuration config = ConfigurationManager.OpenMappedExeConfiguration(fileMap, ConfigurationUserLevel.None);

        // Get the desired section
        ConfigurationSection section = config.GetSection(sectionName);

        // Encrypt the section
        if (!section.SectionInformation.IsProtected)
            section.SectionInformation.ProtectSection(protectionProviderName);

        // Save configuration file
        config.Save();
    }

    ///
    /// Encrypts a section in a .NET configuration file using DataProtectionProvider.
    ///
    /// Physical path of configuration file.
    /// Section name to encrypt.
    public static void EncryptConfigSection(string configPath, string sectionName)
    {
        EncryptConfigSection(configPath, sectionName, &quot;DataProtectionConfigurationProvider&quot;);
    }

    #endregion

    #region Decryption Methods

    ///
    /// Decrypts a section in a .NET configuration file.
    ///
    /// Physical path of configuration file.
    /// Section name to encrypt.
    public static void DecryptConfigSection(string configPath, string sectionName)
    {
        // Map the configuration file
        ExeConfigurationFileMap fileMap = new ExeConfigurationFileMap();
        fileMap.ExeConfigFilename = configPath;

        // Open configuration file
        Configuration config = ConfigurationManager.OpenMappedExeConfiguration(fileMap, ConfigurationUserLevel.None);

        // Get the desired section
        ConfigurationSection section = config.GetSection(sectionName);

        // Decrypt section
        if (section.SectionInformation.IsProtected)
            section.SectionInformation.UnprotectSection();

        // Save configuration file
        config.Save();

    }

    #endregion
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2006/10/net-2-0-on-demand-configuration-encryption/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adding Controls To ASP.NET GridView Pager Row</title>
		<link>http://www.softwarerockstar.com/2006/09/adding-controls-to-asp-net-gridview-pager-row/</link>
		<comments>http://www.softwarerockstar.com/2006/09/adding-controls-to-asp-net-gridview-pager-row/#comments</comments>
		<pubDate>Thu, 14 Sep 2006 22:53:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2006/09/14/adding-controls-to-asp-net-gridview-pager-row/</guid>
		<description><![CDATA[ASP.NET 2.0 GridView control contains the AllowPaging property. Setting this property to a value of true enables the paging feature of the GridView and displays data split across multiple pages if the number of rows in the underlying data source is greater than the PageSize property. By default ASP.NET automatically displays numeric paging controls at [...]]]></description>
			<content:encoded><![CDATA[<p>ASP.NET 2.0 <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a> control contains the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.allowpaging.aspx">AllowPaging</a> property. Setting this property to a value of true enables the paging feature of the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a> and displays data split across multiple pages if the number of rows in the underlying data source is greater than the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.pagesize.aspx">PageSize</a> property. By default ASP.NET automatically displays numeric paging controls at the bottom of the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a>.</p>
<p>While automatic paging is a very handy feature of <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a>, if you want to display any additional paging controls than those inherently supported by automatic paging, you must resort to specifying your own <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.pagertemplate.aspx">PagerTemplate</a> and write some additional code to preform the same functionality that <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a> would otherwise handle for you.</p>
<p>In certain situations, a better option, however, is to simply inject your custom control(s) into the pager generated by the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a>. The following example shows how we can inject a &#8220;View All&#8221; <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.linkbutton.aspx">LinkButton</a> into <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView&#8217;s</a> pager row that allows users to view all rows in the underlying data source at the same time:</p>
<pre class="brush: csharp">
protected void MyGridView_RowCreated(object sender, GridViewRowEventArgs e)
{
    if (e.Row.RowType == DataControlRowType.Pager)
    {
        LiteralControl space = new LiteralControl(&quot;&amp;nbsp;&quot;);

        LinkButton lb = new LinkButton();
        lb.ID = &quot;ViewAllLinkButton&quot;;
        lb.Text = &quot;View All&quot;;
        lb.SkinID = &quot;ProfessionalGridViewPagerViewAll&quot;;
        lb.Click += new EventHandler(ViewAllLinkButton_Click);

        // Pager is rendered in a single cell as a table;
        // each page # is in a cell by it&#039;s own
        Table table = e.Row.Cells[0].Controls[0] as Table;

        // Add ViewAll linkbutton to the last cell
        TableCell parentCell = table.Rows[0].Cells[table.Rows[0].Cells.Count - 1];
        parentCell.Controls.Add(space);
        parentCell.Controls.Add(lb);
    }
}

protected void ViewAllLinkButton_Click(object sender, EventArgs e)
{
    MyGridView.AllowPaging = false;
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2006/09/adding-controls-to-asp-net-gridview-pager-row/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>ASP.NET GridView And Conditional Images</title>
		<link>http://www.softwarerockstar.com/2006/09/asp-net-gridview-and-conditional-images/</link>
		<comments>http://www.softwarerockstar.com/2006/09/asp-net-gridview-and-conditional-images/#comments</comments>
		<pubDate>Thu, 14 Sep 2006 22:37:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ADO.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2006/09/14/asp-net-gridview-and-conditional-images/</guid>
		<description><![CDATA[Depending upon a value in the data source, we can conditionally display images in GridView columns. For example, the following TemplateField declaration conditionally displays approved.gif or unapproved.gif based on IsApproved flag in the DataSet that the GridView is bound to: &#60;asp :Image ID=&#34;ApprovalImage&#34; runat=&#34;server&#34; ImageUrl=&#34;&#34; /&#62;]]></description>
			<content:encoded><![CDATA[<p>Depending upon a value in the data source, we can conditionally display images in <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a> columns. For example, the following <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.templatefield.aspx">TemplateField</a> declaration conditionally displays approved.gif or unapproved.gif based on IsApproved flag in the <a href="http://msdn2.microsoft.com/en-us/library/system.data.dataset.aspx">DataSet</a> that the <a href="http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.aspx">GridView</a> is bound to:</p>
<pre class="brush: csharp">
&lt;asp :Image ID=&quot;ApprovalImage&quot; runat=&quot;server&quot; ImageUrl=&quot;&quot; /&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2006/09/asp-net-gridview-and-conditional-images/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>ASP.NET 2.0 Web Application Projects</title>
		<link>http://www.softwarerockstar.com/2006/09/asp-net-2-0-web-application-projects/</link>
		<comments>http://www.softwarerockstar.com/2006/09/asp-net-2-0-web-application-projects/#comments</comments>
		<pubDate>Thu, 14 Sep 2006 01:14:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Cool Tools]]></category>
		<category><![CDATA[Deployment]]></category>
		<category><![CDATA[Release Management]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2006/09/13/asp-net-2-0-web-application-projects/</guid>
		<description><![CDATA[I recently posted about how the lack of project files in Visual Studio 2005 Web Site Projects make it difficult to deploy web applications. I just came across this add-in for Visual Studio 2005 that actually addresses this very issue. It&#8217;s called the Visual Studio 2005 Web Application Projects (WAP) and is available as a [...]]]></description>
			<content:encoded><![CDATA[<div class="imageleft"><img src="http://softwarerockstar.com/wp-content/uploads/2006/09/aspnetlogo1.png" alt="ASP.NET Logo" width="291" class="alignnone size-full wp-image-327" /></div>
<p>I <a href="http://mfharoon.blogspot.com/2006/08/aspnet-20-deployment.html">recently posted</a> about how the lack of project files in Visual Studio 2005 Web Site Projects make it difficult to deploy web applications.</p>
<p>I just came across this add-in for Visual Studio 2005 that actually addresses this very issue. It&#8217;s called the <a href="http://msdn.microsoft.com/asp.net/reference/infrastructure/wap/">Visual Studio 2005 Web Application Projects</a> (WAP) and is available as a free download from Microsoft. WAP provides following features to ASP.NET 2.0 Web Site Projects in Visual Studio 2005:</p>
<ol>
<li>A project file that contains references to all web content as well as any assembly references.</li>
<li>Compilation into single assembly that is built into the bin folder.</li>
<li>Pre and Post Build actions.</li>
</ol>
<p>While WAP is aimed at developers converting web applications from Visual Studio 2003, I think that it&#8217;s an invaluable tool for anyone creating web applications using Visual Studio 2005.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2006/09/asp-net-2-0-web-application-projects/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Enumerating Cache Items</title>
		<link>http://www.softwarerockstar.com/2006/09/enumerating-cache-items/</link>
		<comments>http://www.softwarerockstar.com/2006/09/enumerating-cache-items/#comments</comments>
		<pubDate>Thu, 14 Sep 2006 01:12:00 +0000</pubDate>
		<dc:creator>SoftwareRockstar</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>

		<guid isPermaLink="false">http://mharoon.wordpress.com/2006/09/13/enumerating-cache-items/</guid>
		<description><![CDATA[System.Web.Caching.Cache object implements the IDictionary interface, hence we can retreive a list of cached item keys as follows: protected ReadOnlyCollection GetCacheItemList() { List cacheItemList = new List(Cache.Count); IDictionaryEnumerator cacheEnum = Cache.GetEnumerator(); while (cacheEnum.MoveNext()) { DictionaryEntry cacheItem = (DictionaryEntry)cacheEnum.Current; cacheItemList.Add(cacheItem.Key.ToString()); } return new ReadOnlyCollection(cacheItemList); }]]></description>
			<content:encoded><![CDATA[<p><a href="http://msdn2.microsoft.com/en-us/library/system.web.caching.cache.aspx">System.Web.Caching.Cache</a> object implements the <a href="http://msdn2.microsoft.com/en-us/library/system.collections.idictionary.aspx">IDictionary</a> interface, hence we can retreive a list of cached item keys as follows:</p>
<pre class="brush: csharp">
protected ReadOnlyCollection GetCacheItemList()
{
    List cacheItemList = new List(Cache.Count);

    IDictionaryEnumerator cacheEnum = Cache.GetEnumerator();
    while (cacheEnum.MoveNext())
    {
        DictionaryEntry cacheItem = (DictionaryEntry)cacheEnum.Current;
        cacheItemList.Add(cacheItem.Key.ToString());
    }

    return new ReadOnlyCollection(cacheItemList);
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.softwarerockstar.com/2006/09/enumerating-cache-items/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->