<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>ASP.NET Weblogs</title><link>http://weblogs.asp.net/</link><description /><dc:language>en-US</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>jQuery Tip #2 - Manipulating the DOM in a Loop</title><link>http://weblogs.asp.net/dwahlin/archive/2012/02/08/jquery-tip-2-manipulating-the-dom-in-a-loop.aspx</link><pubDate>Thu, 09 Feb 2012 06:22:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8290248</guid><dc:creator>dwahlin</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;One of jQuery's greatest strengths is its ability to manipulate the DOM with a minimal amount of code. It's so easy to change things that we often don't think about what's happening under the covers. For example, consider the following code that appends nodes to an object named parentDiv.&lt;/p&gt;  &lt;p&gt;   &lt;br /&gt;    &lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;parentDiv = $(&lt;span style="color: maroon"&gt;'#emailList'&lt;/span&gt;);
&lt;span style="color: blue"&gt;for &lt;/span&gt;(&lt;span style="color: blue"&gt;var &lt;/span&gt;i = 0; i &amp;lt; 100; i++) {
    parentDiv.append(&lt;span style="color: maroon"&gt;'&amp;lt;div&amp;gt;' &lt;/span&gt;+ i + &lt;span style="color: maroon"&gt;'&amp;lt;/div&amp;gt;'&lt;/span&gt;);
}&lt;br /&gt;&lt;/pre&gt;
  &lt;/p&gt;

&lt;p&gt;This is one of the more common ways to append nodes into a given parent. Although it works fine, it's not optimal because jQuery has to constantly perform DOM operations in the loop. You may not notice a problem when looping through 100 items, but as that number increases to a larger number the performance can start to degrade. A more efficient (yet simple) approach from a performance standpoint is shown next:&lt;/p&gt;

&lt;p&gt;
  &lt;br /&gt;

  &lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;parentDiv = $(&lt;span style="color: maroon"&gt;'#emailList'&lt;/span&gt;);
&lt;span style="color: blue"&gt;var &lt;/span&gt;divs = &lt;span style="color: maroon"&gt;''&lt;/span&gt;;
&lt;span style="color: blue"&gt;for &lt;/span&gt;(&lt;span style="color: blue"&gt;var &lt;/span&gt;i = 0; i &amp;lt; 100; i++) {
  divs += &lt;span style="color: maroon"&gt;'&amp;lt;div&amp;gt;' &lt;/span&gt;+ i + &lt;span style="color: maroon"&gt;'&amp;lt;/div&amp;gt;'&lt;/span&gt;;
}
parentDiv.html(divs);&lt;br /&gt;&lt;/pre&gt;
  &lt;/p&gt;

&lt;p&gt;The previous code only touches the DOM once after the loop has completed resulting in better overall performance. While a lot of string concatenation is occurring, it turns out that going that route is much more efficient than calling append() multiple times. &lt;/p&gt;

&lt;p&gt;Keep in mind that you can always manipulate the DOM directly as well and increase performance even more in some cases by using things like document.createDocumentFragment() and other techniques. While I prefer to use jQuery functions whenever possible, sometimes it's necessary to step outside of jQuery’s API for a given task and use the native DOM API instead. &lt;/p&gt;

&lt;p&gt;A test page available at &lt;a href="http://jsperf.com/strings-vs-array-join-vs-doc-fragment/8"&gt;http://jsperf.com/strings-vs-array-join-vs-doc-fragment/8&lt;/a&gt; shows different techniques that can be used for updating the DOM while using a loop as well as their individual performance results. An example of the test results and the different techniques tested are shown next. You’ll notice that calling jQuery’s append() function in a loop doesn’t fare too well compared to some of the other more “native” DOM options.

  &lt;br /&gt;&lt;/p&gt;

&lt;table style="border-collapse: collapse; margin-bottom: 16px" id="test-table" width="960"&gt;&lt;thead style="margin-bottom: 16px"&gt;
    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom-color: ; padding-bottom: 3px; background-color: rgb(26,106,185); padding-left: 8px; padding-right: 8px; border-bottom-width: 0px; color: ; padding-top: 3px; background-origin: initial; background-clip: initial" colspan="2" align="center"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt" color="#ffffff"&gt;Test&lt;/font&gt;&lt;/font&gt;&lt;/th&gt;

      &lt;th style="border-bottom-color: ; padding-bottom: 3px; background-color: rgb(26,106,185); padding-left: 8px; padding-right: 8px; border-bottom-width: 0px; color: ; padding-top: 3px; background-origin: initial; background-clip: initial" title="Operations per second (higher is better)" align="center"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt" color="#ffffff"&gt;Ops/sec&lt;/font&gt;&lt;/font&gt;&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;&lt;tbody style="margin-bottom: 16px"&gt;
    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-1" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;Strings&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; str &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;''&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;li&amp;gt;'&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;/li&amp;gt;'&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; str &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+=&lt;/font&gt;&lt;/span&gt; c&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;innerHTML&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; str&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; border-image: initial" id="results-1" class="results" title="Ran 70 times in 0.057 seconds." width="100" align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;1,226&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±0.84%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;61% slower&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-2" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;Array (using push)&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; arr &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;font color="#009900"&gt;&lt;span style="color: " class="br0"&gt;[&lt;/span&gt;&lt;span style="color: " class="br0"&gt;]&lt;/span&gt;&lt;/font&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;li&amp;gt;'&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;/li&amp;gt;'&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; arr.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;push&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;c&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;innerHTML&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; arr.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;join&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;''&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; border-image: initial" id="results-2" class="results" title="Ran 66 times in 0.054 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;1,234&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±0.35%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;61% slower&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-3" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;Doc Fragment&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; doc &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;createDocumentFragment&lt;/font&gt;&lt;/span&gt;&lt;font color="#009900"&gt;&lt;span style="color: " class="br0"&gt;(&lt;/span&gt;&lt;span style="color: " class="br0"&gt;)&lt;/span&gt;&lt;/font&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; &lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; e &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;createElement&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;&amp;quot;li&amp;quot;&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; e.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;textContent&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; c&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; doc.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;appendChild&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;e&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;appendChild&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;doc&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; background-color: rgb(156,238,130); padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="results-3" class="results fastest" title="Ran 162 times in 0.054 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;3,020&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±3.24%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;fastest&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-4" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;Array (using index)&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; arr &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;font color="#009900"&gt;&lt;span style="color: " class="br0"&gt;[&lt;/span&gt;&lt;span style="color: " class="br0"&gt;]&lt;/span&gt;&lt;/font&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;li&amp;gt;'&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;/li&amp;gt;'&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; arr&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;[&lt;/font&gt;&lt;/span&gt;i&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;]&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; c&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;innerHTML&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; arr.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;join&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;''&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; border-image: initial" id="results-4" class="results" title="Ran 68 times in 0.056 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;1,223&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±0.46%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;61% slower&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-5" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;Array join then string concat&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; arr &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;font color="#009900"&gt;&lt;span style="color: " class="br0"&gt;[&lt;/span&gt;&lt;span style="color: " class="br0"&gt;]&lt;/span&gt;&lt;/font&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; arr&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;[&lt;/font&gt;&lt;/span&gt;i&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;]&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; c&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;innerHTML&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;li&amp;gt;'&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; arr.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;join&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;/li&amp;gt;'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; border-image: initial" id="results-5" class="results" title="Ran 71 times in 0.057 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;1,252&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±0.37%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;60% slower&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-6" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;DOM List&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; list &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; &lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; e &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;createElement&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;&amp;quot;li&amp;quot;&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; e.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;textContent&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; c&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; list.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;appendChild&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;e&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; background-color: rgb(156,238,130); padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="results-6" class="results fastest" title="Ran 166 times in 0.053 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;3,144&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±0.00%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;fastest&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom: rgb(180,180,180) 1px solid; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-7" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;jquery&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; $list &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; $&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;&amp;quot;#list&amp;quot;&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;li&amp;gt;'&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'&amp;lt;/li&amp;gt;'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; $list.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;append&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;c&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom: rgb(180,180,180) 1px solid; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; background-color: rgb(255,192,203); padding-left: 8px; padding-right: 8px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="results-7" class="results slowest" title="Ran 28 times in 0.065 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;428&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±9.06%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;86% slower&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr style="margin-bottom: 16px"&gt;
      &lt;th style="border-bottom-color: ; min-width: 100px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: rgb(221,228,234); padding-left: 8px; padding-right: 8px; border-bottom-width: 0px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="title-8" title="Click to run this test again." tabindex="tabindex" scope="row" align="center"&gt;
        &lt;div style="overflow-x: auto; overflow-y: auto; max-width: 200px; word-wrap: break-word"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 12pt"&gt;doc fragment 2&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
      &lt;/th&gt;

      &lt;td style="border-bottom: 0px; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; background-color: transparent; padding-left: 8px; padding-right: 8px; border-top: rgb(180,180,180) 0px solid; border-right: rgb(180,180,180) 1px solid; padding-top: 3px; border-image: initial" class="code" width="650"&gt;
        &lt;pre style="overflow-x: auto; overflow-y: auto; width: 650px; word-wrap: break-word; white-space: pre-wrap"&gt;&lt;code style="font-family: "&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; doc &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;createDocumentFragment&lt;/font&gt;&lt;/span&gt;&lt;font color="#009900"&gt;&lt;span style="color: " class="br0"&gt;(&lt;/span&gt;&lt;span style="color: " class="br0"&gt;)&lt;/span&gt;&lt;/font&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; c &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;first&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;' '&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;+&lt;/font&gt;&lt;/span&gt; d.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;second&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; e &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;createElement&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;&amp;quot;li&amp;quot;&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;e.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;textContent&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; c&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="kw1"&gt;&lt;font color="#000066"&gt;for&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;var&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;=&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;0&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i &lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;&amp;lt;&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="nu0"&gt;&lt;font color="#cc0000"&gt;100&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt; i&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;++&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt; &lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&amp;#160; doc.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;appendChild&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;e.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;cloneNode&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="kw2"&gt;&lt;font color="#003366"&gt;true&lt;/font&gt;&lt;/span&gt;&lt;font color="#009900"&gt;&lt;span style="color: " class="br0"&gt;)&lt;/span&gt;&lt;span style="color: " class="br0"&gt;)&lt;/span&gt;&lt;/font&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;br /&gt;document.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;getElementById&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="st0"&gt;&lt;font color="#3366cc"&gt;'list'&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;.&lt;span style="color: " class="me1"&gt;&lt;font color="#660066"&gt;appendChild&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;(&lt;/font&gt;&lt;/span&gt;doc&lt;span style="color: " class="br0"&gt;&lt;font color="#009900"&gt;)&lt;/font&gt;&lt;/span&gt;&lt;span style="color: " class="sy0"&gt;&lt;font color="#339933"&gt;;&lt;/font&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
      &lt;/td&gt;

      &lt;td style="border-bottom-color: ; border-left: rgb(180,180,180) 0px solid; padding-bottom: 3px; border-right-width: 0px; background-color: rgb(156,238,130); padding-left: 8px; padding-right: 8px; border-bottom-width: 0px; border-right-color: ; border-top: rgb(180,180,180) 0px solid; padding-top: 3px; background-origin: initial; background-clip: initial; border-image: initial" id="results-8" class="results fastest" title="Ran 174 times in 0.054 seconds." align="center"&gt;&lt;font style="font-size: 12pt" face="Times New Roman"&gt;3,241&lt;/font&gt;&lt;small style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;±11.16%&lt;/font&gt;&lt;/font&gt;&lt;/small&gt;&lt;span style="display: block"&gt;&lt;font face="Times New Roman"&gt;&lt;font style="font-size: 9.6pt"&gt;fastest&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;h2 style="padding-bottom: 0px; border-right-width: 0px; margin: 0px 0px 16px; padding-left: 0px; padding-right: 0px; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px; border-image: initial"&gt;
  &lt;br /&gt;Conclusion&lt;/h2&gt;



&lt;p&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px 14px 0px 0px; padding-left: 0px; padding-right: 0px; display: inline; float: left; border-top: 0px; border-right: 0px; padding-top: 0px" border="0" align="left" src="http://media.comicvine.com/uploads/5/54183/1320070-cliff_robertson.gif" width="122" height="92" /&gt;As Peter Parker’s Uncle said in Spider-Man, “With great power comes great responsibility”. The same can be said about the power jQuery provides to developers. Take time to research sections of code that you know are critical for the performance of your application. Just because you can use a particular function doesn’t mean you should. Check out &lt;a href="http://james.padolsey.com/jquery/"&gt;http://james.padolsey.com/jquery/&lt;/a&gt; if you’d like an easy way to see what jQuery functions are doing behind the scenes.&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.pluralsight.com/"&gt;&lt;img border="0" src="http://weblogs.asp.net/blogs/dwahlin/pluralsight.png" /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you’re interested in learning more about jQuery or JavaScript check out my &lt;a href="http://www.pluralsight-training.net/microsoft/Courses/TableOfContents?courseName=jquery-fundamentals"&gt;jQuery Fundamentals&lt;/a&gt; or &lt;a href="http://www.pluralsight-training.net/microsoft/Courses/TableOfContents?courseName=structuring-javascript"&gt;Structuring JavaScript Code&lt;/a&gt; courses from Pluralsight. We also offer onsite/online training options as well at &lt;a href="http://www.thewahlingroup.com"&gt;http://www.thewahlingroup.com&lt;/a&gt;.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8290248" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/dwahlin/archive/tags/.NET/default.aspx">.NET</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/JavaScript/default.aspx">JavaScript</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/jQuery/default.aspx">jQuery</category></item><item><title>jQuery Tip #1 – Defining a Context When Using Selectors</title><link>http://weblogs.asp.net/dwahlin/archive/2012/02/07/jquery-tip-1-defining-a-context-when-using-selectors.aspx</link><pubDate>Wed, 08 Feb 2012 07:06:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8288465</guid><dc:creator>dwahlin</dc:creator><slash:comments>10</slash:comments><description>&lt;p&gt;I really enjoy working with jQuery and have had the opportunity to use it a lot over the years on various projects.&amp;#160; It’s an essential part of my “technology tool belt”. My company has also started providing new &lt;a href="http://www.thewahlingroup.com" target="_blank"&gt;training&lt;/a&gt; classes on jQuery to various companies and I’ve had a lot of great questions come up about best practices, tips and tricks, when certain functions should be used over other functions, and more.&lt;/p&gt;  &lt;p&gt;I decided to put together a series of posts that highlight simple tips and tricks that I’ve used in jQuery applications over the years to provide some guidance to developers new to jQuery and provide answers to different questions I’ve been asked. In this first post I’ll cover an oldie but goodie tip – defining a context when using selectors. It’s something I struggled with when I first started using jQuery but once I found the secret (which is quite easy) it changed how I used selectors and how I used CSS classes in my HTML.    &lt;br /&gt;    &lt;br /&gt;&lt;/p&gt;  &lt;h2&gt;Defining a Context when using Selectors&lt;/h2&gt;  &lt;p&gt;Selectors are an essential part of jQuery that provide a great way to locate nodes in the DOM quickly and easily. For example, the following selector can be used to find all &lt;i&gt;div&lt;/i&gt; elements with a class of &lt;i&gt;panel&lt;/i&gt; on them in a page:     &lt;br /&gt;    &lt;br /&gt;&lt;/p&gt;  &lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;panelDivs = $(&lt;span style="color: maroon"&gt;'div.panel'&lt;/span&gt;); &lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;Selectors are well documented at &lt;a href="http://api.jquery.com/category/selectors"&gt;http://api.jquery.com/category/selectors&lt;/a&gt; so I won't rehash what they are or how to use them here. However, I do want to mention one simple yet powerful tip that many people new to jQuery will find useful. It's one of the tips that I've ended up using over and over as I build applications. To demonstrate the technique let’s walk through a simple example.&lt;/p&gt;

&lt;p&gt;Selectors can be used in the following way to find all elements with a class of &lt;i&gt;panel&lt;/i&gt; on them: 

  &lt;br /&gt;

  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;panels = $(&lt;span style="color: maroon"&gt;'.panel'&lt;/span&gt;);&lt;br /&gt;&lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;However, what if you want to grab all elements with a &lt;i&gt;panel&lt;/i&gt; class that are children of a given parent container element? To better understand the scenario, consider the following HTML: 

  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: maroon"&gt;div &lt;/span&gt;&lt;span style="color: red"&gt;id&lt;/span&gt;&lt;span style="color: blue"&gt;=&amp;quot;emailContainer&amp;quot;&amp;gt;
    &amp;lt;&lt;/span&gt;&lt;span style="color: maroon"&gt;div &lt;/span&gt;&lt;span style="color: red"&gt;class&lt;/span&gt;&lt;span style="color: blue"&gt;=&amp;quot;panel&amp;quot;&amp;gt;
        &lt;/span&gt;…&lt;br /&gt;    &lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: maroon"&gt;div&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
    &amp;lt;&lt;/span&gt;&lt;span style="color: maroon"&gt;div &lt;/span&gt;&lt;span style="color: red"&gt;class&lt;/span&gt;&lt;span style="color: blue"&gt;=&amp;quot;panel&amp;quot;&amp;gt;
        &lt;/span&gt;…&lt;br /&gt;    &lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: maroon"&gt;div&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
&amp;lt;/&lt;/span&gt;&lt;span style="color: maroon"&gt;div&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
&amp;lt;&lt;/span&gt;&lt;span style="color: maroon"&gt;div &lt;/span&gt;&lt;span style="color: red"&gt;id&lt;/span&gt;&lt;span style="color: blue"&gt;=&amp;quot;ordersContainer&amp;quot;&amp;gt;
    &amp;lt;&lt;/span&gt;&lt;span style="color: maroon"&gt;div &lt;/span&gt;&lt;span style="color: red"&gt;class&lt;/span&gt;&lt;span style="color: blue"&gt;=&amp;quot;panel&amp;quot;&amp;gt;
        &lt;/span&gt;…&lt;br /&gt;    &lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: maroon"&gt;div&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
    &amp;lt;&lt;/span&gt;&lt;span style="color: maroon"&gt;div &lt;/span&gt;&lt;span style="color: red"&gt;class&lt;/span&gt;&lt;span style="color: blue"&gt;=&amp;quot;panel&amp;quot;&amp;gt;
        &lt;/span&gt;…&lt;br /&gt;    &lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: maroon"&gt;div&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
&amp;lt;/&lt;/span&gt;&lt;span style="color: maroon"&gt;div&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;br /&gt;
&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;Assume that you already have a reference to the &lt;i&gt;emailContainer&lt;/i&gt; div stored in a variable named &lt;i&gt;emailDiv&lt;/i&gt;: 

  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;emailDiv = $(&lt;span style="color: maroon"&gt;'#emailContainer'&lt;/span&gt;);&lt;br /&gt;&lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;How do you find all div elements with a &lt;i&gt;panel&lt;/i&gt; class on them within the &lt;i&gt;emailDiv&lt;/i&gt; element as opposed to finding every one within the page? One technique is to use the jQuery find() function: 

  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;panels = emailDiv.find(&lt;span style="color: maroon"&gt;'div.panel'&lt;/span&gt;);&lt;br /&gt;&lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;You can alternatively supply a context object to the selector as shown next. This is the technique I normally use mainly because it’s something I’ve used for quite awhile (and old habits are hard to break). 

  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;panels = $(&lt;span style="color: maroon"&gt;'div.panel'&lt;/span&gt;, emailDiv);&lt;br /&gt;&lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;Which way is the best? It depends on who you talk to although you can check out some live performance tests at &lt;a href="http://jsperf.com/jquery-find-vs-context-sel"&gt;http://jsperf.com/jquery-find-vs-context-sel&lt;/a&gt; that infer that find() has a slight performance advantage. Regardless, knowing how to supply a context when using selectors is a great technique to understand and useful in many different scenarios.&lt;/p&gt;

&lt;p&gt;My development team has been using this technique a lot in an application that has several panels with a consistent set of CSS classes defined on elements within each panel. We’re using a plugin that we need to dynamically re-size as the panel changes size and created a function called refreshPanel() that accepts the panel to refresh. The object passed in to the function is used as the context for several selectors (it’s a jQuery object) to identify a starting point for searching elements with specific CSS classes. Here’s a section of a JavaScript file that defines refreshPanel(). &lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;pre class="code"&gt;...&lt;br /&gt;refreshPanel = &lt;span style="color: blue"&gt;function &lt;/span&gt;(panel) {
    &lt;span style="color: blue"&gt;var &lt;/span&gt;padding = 5;
    &lt;span style="color: #006400"&gt;//Handle height
    &lt;/span&gt;&lt;span style="color: blue"&gt;if &lt;/span&gt;(panelHeight == &lt;span style="color: blue"&gt;null&lt;/span&gt;) {
        toolbarH = $(&lt;span style="color: maroon"&gt;'.toolBar'&lt;/span&gt;, panel).height();
        tableHeadH = $(&lt;span style="color: maroon"&gt;'.clientDataTable'&lt;/span&gt;, panel).height();
        maxHeight = $(window).height();
        panelHeight = (maxHeight / panels.length) - toolbarH - (tableHeadH * 2);
    }
    &lt;span style="color: #006400"&gt;//Grab panel's current height
    &lt;/span&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;h = panel.height() - toolbarH - (tableHeadH * 2);
    &lt;span style="color: #006400"&gt;//If panel's height is greater than the original panelHeight assigned in &amp;quot;if&amp;quot; above then they're maximizing
    &lt;/span&gt;&lt;span style="color: blue"&gt;var &lt;/span&gt;newHeight = (h &amp;gt; panelHeight) ? maxHeight - toolbarH - (tableHeadH * 2) : panelHeight;

    &lt;span style="color: blue"&gt;var &lt;/span&gt;w = panel.width();
    $(&lt;span style="color: maroon"&gt;'div.dataTables_scrollBody'&lt;/span&gt;, panel).height(newHeight - padding).width(w);
    $(&lt;span style="color: maroon"&gt;'.dataTables_scrollHeadInner, table.clientDataTable'&lt;/span&gt;, panel).width(w);
}&lt;br /&gt;...&lt;br /&gt;&lt;/pre&gt;

&lt;p&gt;
  &lt;br /&gt;Notice that the panel object is used throughout as the selector context which allows the function to be re-used over and over for multiple panels. We use this technique in several places which allows us to consistently use the same CSS classes over and over within a given panel. 

  &lt;br /&gt;

  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;h2&gt;Conclusion&lt;/h2&gt;

&lt;p&gt;This is the first tip in a series I’ll be writing about jQuery. Although this tip is simple (and hopefully something you already know about if you’re an experienced jQuery developer), it’s very useful in many real-world situations. 
  &lt;br /&gt;

  &lt;br /&gt;&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;div&gt;&lt;a href="http://www.pluralsight.com" target="_blank"&gt;&lt;img style="background-image: none; border-right-width: 0px; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" border="0" src="http://weblogs.asp.net/blogs/dwahlin/pluralsight.png" /&gt;&lt;/a&gt;&amp;#160;&lt;/div&gt;

&lt;div style="margin-bottom: 20px"&gt;If you’re interested in learning more about jQuery or JavaScript check out my &lt;a href="http://www.pluralsight-training.net/microsoft/Courses/TableOfContents?courseName=jquery-fundamentals" target="_blank"&gt;jQuery Fundamentals&lt;/a&gt; or &lt;a href="http://www.pluralsight-training.net/microsoft/Courses/TableOfContents?courseName=structuring-javascript" target="_blank"&gt;Structuring JavaScript Code&lt;/a&gt; courses from Pluralsight. We also offer onsite/online training options as well at &lt;a href="http://www.thewahlingroup.com"&gt;http://www.thewahlingroup.com&lt;/a&gt;. &lt;/div&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8288465" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/dwahlin/archive/tags/.NET/default.aspx">.NET</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/JavaScript/default.aspx">JavaScript</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/jQuery/default.aspx">jQuery</category></item><item><title>Wrapping up Configuration Manager</title><link>http://weblogs.asp.net/psheriff/archive/2012/02/06/wrapping-up-configuration-manager.aspx</link><pubDate>Tue, 07 Feb 2012 03:27:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8286172</guid><dc:creator>psheriff</dc:creator><slash:comments>3</slash:comments><description>&lt;P&gt;Many developers use the ConfigurationManager class to retrieve settings from the .Config file of your application. This class allows you to retrieve settings from the &amp;lt;appSettings&amp;gt; element. With just a single line of code as shown in the following line:&lt;/P&gt;&lt;PRE&gt;file = ConfigurationManager.AppSettings["CustomerFile"];&lt;/PRE&gt;
&lt;P&gt;The above code assumes you have the following setting declared in your App.Config or Web.Config file for your application:&lt;/P&gt;
&lt;P&gt;&amp;lt;configuration&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;appSettings&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;add key="CustomerFile" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; value="D:\Samples\Customers.xml" /&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/appSettings&amp;gt;&lt;BR&gt;&amp;lt;/configuration&amp;gt;&lt;/P&gt;
&lt;P&gt;This works great except in the case where you misspell the key name in your line of code, or you forget to add the element in the &amp;lt;appSettings&amp;gt; element in your .Config file. In either case, the value you get back will be a null value. Sometimes these null values can wreak havoc on your code because you forgot to check the value for null and the attempt to perform some operation on that value such as opening the file name. For example, the following code would cause a ArgumentNullException to be raised because the key value is misspelled.&lt;/P&gt;&lt;PRE&gt;string value = string.Empty;

value = ConfigurationManager.AppSettings["CustomerFil"];

System.IO.File.OpenText(value);
&lt;/PRE&gt;
&lt;P&gt;To fix the above code you need to test the “value” variable to see it is null prior to attempting to open the file as shown in the following code:&lt;/P&gt;&lt;PRE&gt;string value = string.Empty;

value = ConfigurationManager.AppSettings["TheValue"];

if (value == null)
  MessageBox.Show("Can't open the file");
else
  System.IO.File.OpenText(value);

MessageBox.Show(value.ToString());
&lt;/PRE&gt;
&lt;P&gt;Another issue with the above code is if you wish to change the location of where you are storing your application settings, you have to modify every line of code throughout your whole application where you used ConfigurationManager.AppSettings. For example, sometime in the future you might want to store your settings in an XML file located on a central server, or maybe store them in a database. This would be a lot of extra work due to you probably have a lot of places where you are retrieving configuration settings. Instead let’s wrap up the calls to the ConfigurationManager.AppSettings method in your own class.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Wrap Up Configuration Manager&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;A best practice that I have employed for over twenty years has been to wrap up any method calls that could potentially change in the future. Configuration settings, database access calls, registry settings, WCF Services, and similar types of classes are all candidates for wrapping up. Creating your own class allows you to change the methods for getting data from another source without you having to change the code in your application.&lt;/P&gt;
&lt;P&gt;For the configuration settings shown previously, creating a class to wrap up the call to ConfigurationManager.AppSettings is a very simple task. Below is the complete class that will allow you to get a string and an integer value from a configuration file.&lt;/P&gt;&lt;PRE&gt;public class AppConfig
{
  public string XmlPath { get; set; }
  public int DefaultType { get; set; }

  // Wrapper around ConfigurationManager.AppSettings call
  protected string GetSetting(string key)
  {
    return ConfigurationManager.AppSettings[key];
  }

  public string GetSetting(string key, string defaultValue)
  {
    string value;

    value = GetSetting(key);
    if (value == null)
      value = defaultValue;

    return value;
  }

  public int GetSetting(string key, int defaultValue)
  {
    int ret;
    string value;

    value = GetSetting(key);
    if (value == null)
      ret = defaultValue;
    else
      ret = Convert.ToInt32(value);

    return ret;
  }
}
&lt;/PRE&gt;
&lt;P&gt;Notice how each of the public GetSetting methods call a protected method named GetSetting where the call to ConfigurationManager.AppSettings is made. Now, if you want to store your configuration settings in a database table, you only need to change the protected GetSetting method. All of the rest of the methods in this class and the calls you make in your application to the GetSetting methods in this class do not need to change at all.&lt;/P&gt;
&lt;P&gt;In addition to wrapping up the call to the ConfigurationManager.AppSettings method call, you can add on additional functionality as well. For instance you can allow the programmer to pass in a default value to return if the value is not found in your settings storage location.&lt;/P&gt;
&lt;P&gt;You call the GetSetting methods in AppConfig class using the following code:&lt;/P&gt;&lt;PRE&gt;AppConfig config = new AppConfig();

config.XmlPath = config.GetSetting("XmlPath", @"C:\");

MessageBox.Show(config.XmlPath);
&lt;/PRE&gt;
&lt;P&gt;In the above code if the “XmlPath” key was not found, then C:\ would be returned. The same call can be used for the overloaded version of GetSetting that returns an integer value. You pass in an integer value that you wish to have returned if the key “DefaultType” is not found. &lt;/P&gt;&lt;PRE&gt;AppConfig config = new AppConfig();

config.DefaultType = config.GetSetting("DefaultType", 1);

MessageBox.Show(config.DefaultType.ToString());
&lt;/PRE&gt;
&lt;P&gt;&lt;STRONG&gt;Summary&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Wrapping up calls to .NET classes and their methods can give you more flexibility in the future if you wish to change the implementation of a method. In addition it allows you to add on functionality that is not present in the original calls. Wrapping up methods like this also protects you from changes that Microsoft might introduce in future versions of the .NET Framework. If they obsolete a class or method, you now only need to change your code in just place. The rest of your application does not need to change. In other words, you are helping to future-proof your code.&lt;/P&gt;
&lt;P&gt;NOTE: You can download this article and the sample code that goes with this blog entry at my website. &lt;A href="http://www.pdsa.com/downloads" mce_href="http://www.pdsa.com/downloads"&gt;http://www.pdsa.com/downloads&lt;/A&gt;. Select “Tips and Tricks”, then “Wrapping up Configuration Manager” from the drop down list.&lt;/P&gt;
&lt;P&gt;Good Luck with your Coding,&lt;BR&gt;Paul Sheriff&lt;/P&gt;
&lt;P&gt;** SPECIAL OFFER FOR MY BLOG READERS **&lt;BR&gt;We frequently offer a FREE gift for readers of my blog. Visit &lt;A href="http://www.pdsa.com/Event/Blog" mce_href="http://www.pdsa.com/Event/Blog"&gt;http://www.pdsa.com/Event/Blog&lt;/A&gt; for your FREE gift!&lt;BR&gt;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8286172" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/psheriff/archive/tags/.NET/default.aspx">.NET</category></item><item><title>AgileSight, my new venture</title><link>http://weblogs.asp.net/cibrax/archive/2012/02/06/agilesight-my-new-venture.aspx</link><pubDate>Mon, 06 Feb 2012 14:05:33 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8285350</guid><dc:creator>cibrax</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;Another important milestone in my career started three years ago when I joined &lt;a href="http://www.tellago.com"&gt;Tellago&lt;/a&gt;. I convinced my friend &lt;a href="http://weblogs.asp.net/gsusx"&gt;Jesus&lt;/a&gt; to hire me, and I would eventually move to the United States with my family to work in the company.&amp;#160; That never occurred for some personal things, but I fortunately had a chance to create an excellent team of very talented people in Argentina. I started myself working remotely from Argentina, and the things went so well for the company that we end up hiring more than 15 great architects down here in Argentina.&amp;#160; Creating this team was a very interesting and completely new challenge in my career.&lt;/p&gt;  &lt;p&gt;I also got involved in a lot of interesting projects, and what is more important, I had a chance to work and met great people, which is what it really worth it. &lt;/p&gt;  &lt;p&gt;However, a month ago, I decided it was about time to start a personal project with a &lt;a href="http://www.linkedin.com/pub/pablo-galiano/3/592/aba"&gt;good friend of mine&lt;/a&gt;, and that’s how &lt;a href="http://agilesight.com"&gt;AgileSight&lt;/a&gt; was born. Although the initial conception of the company was to create software products, we will also offering software consulting and development services. I am definitely very excited to be part of this new venture and face all new kind of challenges ahead. &lt;/p&gt;  &lt;p&gt;My first assignment in AgileSight couldn’t be better as I will be working in the next Web Mobile Guidance project (&lt;a href="http://liike.github.com/team/"&gt;Liike project&lt;/a&gt;) with the Microsoft Patterns &amp;amp; Practices team.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8285350" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/cibrax/archive/tags/.NET/default.aspx">.NET</category><category domain="http://weblogs.asp.net/cibrax/archive/tags/Personal/default.aspx">Personal</category></item><item><title>Upcoming ASP.NET, HTML5 and Windows 8 Talks and Workshops at DevConnections 2012</title><link>http://weblogs.asp.net/dwahlin/archive/2012/02/04/upcoming-asp-net-html5-and-windows-8-talks-and-workshops-at-devconnections-2012.aspx</link><pubDate>Sun, 05 Feb 2012 00:15:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8282153</guid><dc:creator>dwahlin</dc:creator><slash:comments>2</slash:comments><description>&lt;p&gt;It’s that time of the year again! &lt;a href="http://devconnections.com/home.aspx" target="_blank"&gt;DevConnections 2012&lt;/a&gt; is right around the corner and we have a lot of great new workshops and sessions planned for the ASP.NET and Client-Dev (HTML5, Windows 8 Metro, JavaScript, jQuery, etc.) tracks. &lt;/p&gt;  &lt;p&gt;The keynote at DevConnections will be given by the one and only &lt;a href="https://twitter.com/#!/scottgu" target="_blank"&gt;Scott Guthrie&lt;/a&gt; who’s always up to something cool and is a lot of fun to listen to.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://devconnections.com/shows/sp2012/registration.aspx?s=183"&gt;&lt;img title="image" border="0" alt="image" src="http://johnpapa.net/Media/Default/Windows-Live-Writer/Spring-2012-DevConnections_C09C/image_19.png" width="504" height="107" /&gt;&lt;/a&gt;    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;Several other great speakers will be at the conference as well. Here’s a quick sampling:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a href="https://twitter.com/#!/John_Papa" target="_blank"&gt;John Papa&lt;/a&gt; (awesome presenter and a close personal friend of mine) &lt;/li&gt;    &lt;li&gt;&lt;a href="https://twitter.com/#!/shanselman"&gt;Scott Hanselman&lt;/a&gt; (everyone’s favorite speaker/comedian)&lt;/li&gt;    &lt;li&gt;&lt;a href="https://twitter.com/#!/swalther"&gt;Stephen Walther&lt;/a&gt;&amp;#160; (one of the smartest people I’ve met and a great guy)&lt;/li&gt;    &lt;li&gt;&lt;a href="https://twitter.com/#!/richcampbell"&gt;Richard Campbell&lt;/a&gt; (super fun guy who’s a blast to listen/talk to on &lt;a href="http://dotnetrocks.com/" target="_blank"&gt;.NET Rocks&lt;/a&gt;)&lt;/li&gt;    &lt;li&gt;&lt;a href="https://twitter.com/#!/mkristensen"&gt;Mads Kristensen&lt;/a&gt; (of Visual Studio plugin fame)&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;a href="http://devconnections.com/shows/sp2012/registration.aspx?s=183"&gt;&lt;img title="image" border="0" alt="image" src="http://johnpapa.net/Media/Default/Windows-Live-Writer/Spring-2012-DevConnections_C09C/image_16.png" width="504" height="106" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;And of course there are many more! Sessions are only part of a conference experience. Yeah there are the parties too … but the real value is in the hallway conversations and the people you meet and continue to talk to beyond the conference event. DevConnections is a great place to strike up these conversations as its one of the largest gatherings of super experts in our industry … and they are all very approachable. There will also be a panel discussions with many of us, which is a great chance to put us on the spot.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;…&lt;/strong&gt;Thanks to John for letting me hijack that last paragraph along with the pictures he put on his &lt;a href="http://johnpapa.net/" target="_blank"&gt;blog&lt;/a&gt;. I thought he nailed what DevConnections is all about in just a few sentences.&lt;/p&gt;  &lt;p&gt;I’ll be co-presenting a full day jQuery workshop with John on Monday, March 26th. We really enjoy co-presenting and have a lot of great jQuery topics to discuss. You do have to register for the workshops so make sure to do that when you register for the conference.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://devconnections.com/shows/sp2012/registration.aspx?s=183"&gt;&lt;img title="image" border="0" alt="image" src="http://johnpapa.net/Media/Default/Windows-Live-Writer/Spring-2012-DevConnections_C09C/image_12.png" width="504" height="107" /&gt;&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Workshop&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;&lt;b&gt;APR02: Building Ajax-Enabled Applications with jQuery (9:00AM - 4:00PM) &lt;/b&gt;    &lt;br /&gt;&lt;b&gt;Add'l Fee $399.00&lt;/b&gt;    &lt;br /&gt;John Papa &amp;amp; Dan Wahlin    &lt;br /&gt;    &lt;br /&gt;Building cross-browser AJAX applications can be a fun yet challenging proposition. In this workshop, you’ll learn how to put the joy back into AJAX development using the jQuery script library. Learn how jQuery selectors can reduce code and simplify the process of finding DOM elements, how chaining can be used to accomplish multiple tasks with a single line of code and how cross-browser AJAX calls can be made using built-in jQuery functionality. Other topics covered include using client-side templates as well as built-in plugins. If you’ve wanted to learn jQuery but haven’t made the time, this is the workshop for you since we’ll take you from the ground floor all the way to the top.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Sessions&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;I’m also presenting or co-presenting 4 other sessions. If you’ll be at the conference please stop by and introduce yourself.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://devconnections.com/shows/sp2012/registration.aspx?s=183"&gt;&lt;img title="image" border="0" alt="image" src="http://johnpapa.net/Media/Default/Windows-Live-Writer/Spring-2012-DevConnections_C09C/image_11.png" width="504" height="109" /&gt;&lt;/a&gt;    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;&lt;b&gt;CWI202: Fundamentals of Windows 8 HTML/JavaScript Metro Style Apps&lt;/b&gt;    &lt;br /&gt;Dan Wahlin    &lt;br /&gt;    &lt;br /&gt;Heard the buzz about Windows 8 Metro style applications but don’t know where to start? In this session, you’ll learn how your existing HTML, JavaScript, and CSS skills can be used to build Windows 8 Metro applications. Learn about different Visual Studio 11 project templates, built-in scripts, and Windows Runtime (WinRT) calls that you can make to build robust applications that will be capable of targeting millions of Windows users on the desktop and on tablets in the near future.    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;&lt;b&gt;CHT201: Developing an HTML5/jQuery Application - End to End&lt;/b&gt;    &lt;br /&gt;Dan Wahlin    &lt;br /&gt;    &lt;br /&gt;HTML5 is all the rage these days but where do you look to find robust examples of using it along with jQuery, jQuery templates, Ajax calls, data access technologies, and more? In this session, Dan Wahlin will walk through an application called Account at a Glance that demonstrates how key HTML5 technologies can be integrated and used to present data to users in different ways. Topics covered include exposing data to the client using Entity Framework Code First and RESTful services, using jQuery templates to render data, JavaScript techniques for structuring code, the role of HTML5 semantic tags, as well as how technologies such as the canvas, SVG, and video can be used. If you want to learn HTML5 techniques and strategies from a real app, then this session is for you.    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;&lt;b&gt;CJS301: Techniques, Strategies, and Patterns for Structuring JavaScript Code &lt;/b&gt;    &lt;br /&gt;John Papa &amp;amp; Dan Wahlin    &lt;br /&gt;    &lt;br /&gt;Are you writing a lot of JavaScript code and trying to apply good practices to make it more maintainable and flexible? In this session, learn about common practices to make avoid problems such as polluting the global namespace and code that executes inconsistently, by using patterns such as separation and the Revealing Module Pattern. You will leave this session with several tips on how to write clean, more maintainable, and consistent code.     &lt;br /&gt;    &lt;br /&gt;&lt;strong&gt;&amp;lt;shamelessPlug&amp;gt;     &lt;br /&gt;      &lt;br /&gt;&lt;/strong&gt;If you can’t make the conference make sure to check out my new Structuring JavaScript Code course at &lt;a href="http://www.pluralsight-training.net/microsoft/Courses/TableOfContents?courseName=structuring-javascript" target="_blank"&gt;Pluralsight.com&lt;/a&gt;. If you’re still writing “function spaghetti code” I’ll show you several techniques/patterns that will really improve the re-use and maintainability of your code.Good stuff to know if you’re building Web applications.    &lt;br /&gt;    &lt;br /&gt;&lt;strong&gt;&amp;lt;/shamelessPlug&amp;gt;&lt;/strong&gt;    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;&lt;b&gt;CJS202: Templating and Data Binding for HTML5 Applications with JsRender and JsViews &lt;/b&gt;    &lt;br /&gt;John Papa &amp;amp; Dan Wahlin    &lt;br /&gt;    &lt;br /&gt;Interested in using the latest JavaScript libraries for templating and data binding your HTML5 app? In this session you will learn how to simplify JavaScript development using JsRender and JsViews (the replacements for jQuery templates). Learn how JsRender brings a new templating library to HTML5 development that has a code-less tag syntax, high performance, no dependency on jQuery nor a DOM, supports creating custom functions, and uses pure string-based rendering. You will also see how JsViews compliments JsRender by providing data binding features through observability of changes that work with plain old JavaScript objects (POJO).&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8282153" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/dwahlin/archive/tags/.NET/default.aspx">.NET</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/ASP.NET/default.aspx">ASP.NET</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/ASP.NET+MVC/default.aspx">ASP.NET MVC</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/CSS/default.aspx">CSS</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/Design+Patterns/default.aspx">Design Patterns</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/DevConnections/default.aspx">DevConnections</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/EF+Code+First/default.aspx">EF Code First</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/HTML5/default.aspx">HTML5</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/JavaScript/default.aspx">JavaScript</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/jQuery/default.aspx">jQuery</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/JSON/default.aspx">JSON</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/Metro+Apps/default.aspx">Metro Apps</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/Windows+8/default.aspx">Windows 8</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/WinRT/default.aspx">WinRT</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/XAML/default.aspx">XAML</category><category domain="http://weblogs.asp.net/dwahlin/archive/tags/ASP.NET+AJAX/default.aspx">ASP.NET AJAX</category></item><item><title>Developing custom field type for SharePoint 2010</title><link>http://weblogs.asp.net/sreejukg/archive/2012/02/05/developing-custom-field-type-for-sharepoint-2010.aspx</link><pubDate>Sat, 04 Feb 2012 22:13:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8281980</guid><dc:creator>sreejukg</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;The ECM features of SharePoint 2010 are excellent. The best thing is the extendibility of the platform using SharePoint designer and Visual Studio. By default SharePoint includes field types such as Single line text, multi-line text etc. The following is the snapshot of the fields available in SharePoint 2010&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image001_4B367B9E.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image001_4B367B9E.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image001_thumb_023059D8.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image001" alt="clip_image001" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image001_thumb_023059D8.png" border="0" height="199" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;The out of the box field controls are useful for most situations, but still you may need additional field types when building business applications. Fortunately you can build custom field controls using Visual Studio 2010 and deploy to SharePoint. Custom field control can provide a unique editing and display experience. Custom field controls can be used to include custom client-side validation and a unique editing experience. &lt;/p&gt;  &lt;p&gt;In this article I am going to demonstrate how you can build custom field control for SharePoint 2010. For the purpose of this article, I am going to build a custom field control that inherits the single line of text. When displaying the control, it will show the entered text in &amp;lt;h1&amp;gt; tags. Also the field will convert the text to upper case while displaying. The custom field will throw error if it contains more than 10 characters. The examples looks simple, my intention is to show you how easily you can build custom controls. In real time you can add your business logic to build your own field controls. &lt;/p&gt;  &lt;p&gt;Open Visual Studio, from the file menu select new project. In the new project dialog, select empty SharePoint project as the template. I have named the project as “MyCustomFieldProject”&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image003_7F2ACF57.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image003_7F2ACF57.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image003_thumb_024C9173.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image003" alt="clip_image003" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image003_thumb_024C9173.jpg" border="0" height="128" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;In the SharePoint customization wizard, make sure you select “deploy as farm solution”. Also you can enter the local site URL where you can deploy the custom field.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image004_2DB0B26D.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image004_2DB0B26D.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image004_thumb_290A81E6.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image004" alt="clip_image004" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image004_thumb_290A81E6.png" border="0" height="195" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Click the Finish button. Visual Studio will create an empty project. In Visual Studio solution explorer, the project looks as follows.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image005_760ACBB1.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image005_760ACBB1.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image005_thumb_08731C67.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image005" alt="clip_image005" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image005_thumb_08731C67.png" border="0" height="133" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Now you need to add a class to the solution that represents the custom field. Now right click the project and select Add -&amp;gt; Class&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image007_2F7DB5DC.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image007_2F7DB5DC.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image007_thumb_244405C5.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image007" alt="clip_image007" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image007_thumb_244405C5.jpg" border="0" height="120" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;I have named the class as “MyHeaderField”&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image009_34039AC9.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image009_34039AC9.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image009_thumb_0B085FF3.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image009" alt="clip_image009" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image009_thumb_0B085FF3.jpg" border="0" height="129" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;The class just created have the following code.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image010_5325F602.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image010_5325F602.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image010_thumb_5C9EB478.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image010" alt="clip_image010" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image010_thumb_5C9EB478.png" border="0" height="163" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Now you need to set the class as public. You need to include the using statement to include Microsoft.SharePoint to get access to the Sharepoint built in types. As I mentioned initially MyHeaderField needs to inherit the SharePoint Text field which is “SPFieldText”. Now you need to override the 2 default construtors. After making the mentioned changes, the code file looks as follows.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image012_1EE1A6EF.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image012_1EE1A6EF.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image012_thumb_32CB13B8.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image012" alt="clip_image012" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image012_thumb_32CB13B8.jpg" border="0" height="81" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Now I am going to override 2 methods as follows.&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;GetValidatedString – This will be used to validate the data before saving to database.&lt;/li&gt;    &lt;li&gt;GetFieldValueAsHtml – this is how the value will be displayed in the page.&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;The implementation of the methods are as follows.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image013_50C921AC.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image013_50C921AC.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image013_thumb_2A1A955F.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image013" alt="clip_image013" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image013_thumb_2A1A955F.png" border="0" height="105" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Each field type you define should have a corresponding entry in the form of XML file in the XML folder under 14\Template folder. The XML file will have the following naming convention&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;It should start with fldtypes_&lt;/li&gt;    &lt;li&gt;After _ you can define the field name. It is a good practice to specify the class name as the field name, though it is not a must &lt;/li&gt;    &lt;li&gt;In the XML file, you need to define the fields such as TypeName, parent type name, type display name, corresponding class and assembly. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Now in the Visual Studio project, you need to add a XML file and while deploying it should be deployed to the folder 14\Template\XML. To do this, you can add a mapped folder to your project. Right click the project in solution explorer, select Add -&amp;gt; SharePoint mapped folder&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image015_1B5FC3AD.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image015_1B5FC3AD.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image015_thumb_1EEDB8BD.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image015" alt="clip_image015" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image015_thumb_1EEDB8BD.jpg" border="0" height="127" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;In the Add mapped folder dialog, expand Template and select XML&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image016_0A1BC03D.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image016_0A1BC03D.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image016_thumb_7B246B55.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image016" alt="clip_image016" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image016_thumb_7B246B55.png" border="0" height="244" width="192"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Now you can see the XML folder under your project. Any files created here will be deployed to the 14\Template\XML folder in the SharePoint farm where the solution is deployed. Now you need to add the XML file for your field.&lt;/p&gt;  &lt;p&gt;Right click the project, select Add -&amp;gt; New Item. Now in the template selection, select Data as the category and then select XML as the file type. I have named fldtypes_MyHeaderField.xml&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image018_4824B521.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image018_4824B521.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image018_thumb_08B6DBC4.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image018" alt="clip_image018" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image018_thumb_08B6DBC4.jpg" border="0" height="129" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;I have updated the content of the XML file as follows. Be noted that $SharePoint.Project.AssemblyFullName$ will be replaced automatically by the correct assembly name wile deploying. All the other fields are self-explanatory. &lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image020_5EF360D0.jpg" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image020_5EF360D0.jpg"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image020_thumb_39C5F097.jpg" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image020" alt="clip_image020" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image020_thumb_39C5F097.jpg" border="0" height="76" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Now we are done with all the requirements. From the solution explorer, right click the project and click deploy. &lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image021_70BFCED0.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image021_70BFCED0.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image021_thumb_2ED8E982.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image021" alt="clip_image021" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image021_thumb_2ED8E982.png" border="0" height="86" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Once deployed, you can add new columns to SharePoint lists and libraries with the type “MyHeaderField”. Add the new column to SharePoint types will show the new type you added. &lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image022_017753B2.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image022_017753B2.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image022_thumb_3D736F9A.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image022" alt="clip_image022" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image022_thumb_3D736F9A.png" border="0" height="172" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;I have added a new column named “MyHeader” to my publishing page content type. Now when I try to add text to the column, it will validate it. See a simple validation &lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/sreejukg/clip_image023_2AFAF918.png" mce_href="http://weblogs.asp.net/blogs/sreejukg/clip_image023_2AFAF918.png"&gt;&lt;img src="http://weblogs.asp.net/blogs/sreejukg/clip_image023_thumb_294A2D44.png" style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="clip_image023" alt="clip_image023" mce_src="http://weblogs.asp.net/blogs/sreejukg/clip_image023_thumb_294A2D44.png" border="0" height="34" width="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;SharePoint 2010 is extensible as you can build and deploy custom fields that address your custom business requirements. &lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8281980" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/sreejukg/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://weblogs.asp.net/sreejukg/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://weblogs.asp.net/sreejukg/archive/tags/SharePoint+2010/default.aspx">SharePoint 2010</category><category domain="http://weblogs.asp.net/sreejukg/archive/tags/Visual+Studio/default.aspx">Visual Studio</category><category domain="http://weblogs.asp.net/sreejukg/archive/tags/Visual+Studio+2010/default.aspx">Visual Studio 2010</category></item><item><title>Changing a Control’s Output Dynamically</title><link>http://weblogs.asp.net/ricardoperes/archive/2012/02/04/changing-a-control-s-output-dynamically.aspx</link><pubDate>Sat, 04 Feb 2012 21:18:12 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8281876</guid><dc:creator>Ricardo Peres</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;A question that pops up occasionally in &lt;a href="http://forums.asp.net" target="_blank"&gt;ASP.NET forums&lt;/a&gt; or sites like &lt;a href="http://stackoverflow.com" target="_blank"&gt;Stack Overflow&lt;/a&gt; is how to change a control’s output dynamically. Well, since the &lt;a href="http://code.google.com/p/aspnetcontroladapters/" target="_blank"&gt;CSS Friendly Control Adapters&lt;/a&gt; came out, I knew how to do it statically, through static registration on a &lt;strong&gt;.browser&lt;/strong&gt; file (it can also be done dynamically, for all controls of a certain type, by adding a fully qualified type name to &lt;a href="http://msdn.microsoft.com/en-us/library/system.web.configuration.httpcapabilitiesbase.adapters.aspx" target="_blank"&gt;HttpContext.Current.Request.Browsers.Adapters&lt;/a&gt; collection), but I decided to go and try to do it dynamically, without registration. More specifically, I wanted to achieve two things:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Apply a &lt;a href="http://www.w3.org/TR/xslt" target="_blank"&gt;XSL transformation&lt;/a&gt; to the generated output, provided it is XML-compliant;&lt;/li&gt;    &lt;li&gt;Change the output through code in an event handler-like fashion.&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;So, here’s what I came up with:&lt;/p&gt;  &lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;   &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;     &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &lt;span style="background-color: #ffff00"&gt;&amp;lt;%@ Register Assembly=&amp;quot;WebApplication1&amp;quot; Namespace=&amp;quot;WebApplication1&amp;quot; TagPrefix=&amp;quot;web&amp;quot; %&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt; ...&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;web:OutputAdapterControl&lt;/span&gt; &lt;span style="color: #ff0000"&gt;runat&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;server&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;TargetControlID&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;table&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;OnOutput&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;OnOutput&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;XslPath&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;~/table.xsl&amp;quot;&lt;/span&gt; &lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #800000"&gt;asp:Table&lt;/span&gt; &lt;span style="color: #ff0000"&gt;runat&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;server&amp;quot;&lt;/span&gt; &lt;span style="color: #ff0000"&gt;ID&lt;/span&gt;&lt;span style="color: #0000ff"&gt;=&amp;quot;table&amp;quot;&lt;/span&gt;&lt;span style="color: #0000ff"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;I have two control declarations, one is for a well known &lt;strong&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.table.aspx" target="_blank"&gt;asp:Table&lt;/a&gt;&lt;/strong&gt;, and the other is for my &lt;strong&gt;OutputAdapterControl&lt;/strong&gt;. On its declaration, I have a property that references the &lt;strong&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.table.aspx" target="_blank"&gt;asp:Table&lt;/a&gt;&lt;/strong&gt; through its id, one property for an external XSL transformation file and the final one for registering an event handler.&lt;/p&gt;

&lt;p&gt;The code for the &lt;strong&gt;OutputAdapterControl&lt;/strong&gt; is:&lt;/p&gt;

&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
  &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;
    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;namespace&lt;/span&gt; WebApplication1&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt; {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;     [NonVisualControl]&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; &lt;span style="color: #0000ff"&gt;class&lt;/span&gt; OutputAdapterControl : Control&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt;     {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum6"&gt;   6:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; &lt;span style="color: #0000ff"&gt;static&lt;/span&gt; &lt;span style="color: #0000ff"&gt;readonly&lt;/span&gt; FieldInfo occasionalFieldsField = &lt;span style="color: #0000ff"&gt;typeof&lt;/span&gt;(Control).GetField(&lt;span style="color: #006080"&gt;&amp;quot;_occasionalFields&amp;quot;&lt;/span&gt;, BindingFlags.NonPublic | BindingFlags.Instance);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum7"&gt;   7:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; &lt;span style="color: #0000ff"&gt;static&lt;/span&gt; &lt;span style="color: #0000ff"&gt;readonly&lt;/span&gt; FieldInfo flagsField = &lt;span style="color: #0000ff"&gt;typeof&lt;/span&gt;(Control).GetField(&lt;span style="color: #006080"&gt;&amp;quot;flags&amp;quot;&lt;/span&gt;, BindingFlags.NonPublic | BindingFlags.Instance);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum8"&gt;   8:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum9"&gt;   9:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; OutputAdapterControl()&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum10"&gt;  10:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum11"&gt;  11:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Enabled = &lt;span style="color: #0000ff"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum12"&gt;  12:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum13"&gt;  13:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum14"&gt;  14:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; String XslPath&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum15"&gt;  15:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum16"&gt;  16:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum17"&gt;  17:&lt;/span&gt;             set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum18"&gt;  18:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum19"&gt;  19:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum20"&gt;  20:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; String TargetControlID&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum21"&gt;  21:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum22"&gt;  22:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum23"&gt;  23:&lt;/span&gt;             set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum24"&gt;  24:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum25"&gt;  25:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum26"&gt;  26:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; Boolean Enabled&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum27"&gt;  27:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum28"&gt;  28:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum29"&gt;  29:&lt;/span&gt;             set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum30"&gt;  30:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum31"&gt;  31:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum32"&gt;  32:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; &lt;span style="color: #0000ff"&gt;event&lt;/span&gt; EventHandler&amp;lt;OutputEventArgs&amp;gt; Output;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum33"&gt;  33:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum34"&gt;  34:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; ControlAdapter getControlAdapter(Control control)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum35"&gt;  35:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum36"&gt;  36:&lt;/span&gt;             Object flags = flagsField.GetValue(control);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum37"&gt;  37:&lt;/span&gt;             MethodInfo setMethod = flags.GetType().GetMethod(&lt;span style="color: #006080"&gt;&amp;quot;Set&amp;quot;&lt;/span&gt;, BindingFlags.NonPublic | BindingFlags.Instance);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum38"&gt;  38:&lt;/span&gt;             setMethod.Invoke(flags, &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; Object[] { 0x8000 });&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum39"&gt;  39:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum40"&gt;  40:&lt;/span&gt;             Object occasionalFields = occasionalFieldsField.GetValue(control);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum41"&gt;  41:&lt;/span&gt;             FieldInfo rareFieldsField = occasionalFields.GetType().GetField(&lt;span style="color: #006080"&gt;&amp;quot;RareFields&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum42"&gt;  42:&lt;/span&gt;             Object rareFields = rareFieldsField.GetValue(occasionalFields);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum43"&gt;  43:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum44"&gt;  44:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (rareFields == &lt;span style="color: #0000ff"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum45"&gt;  45:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum46"&gt;  46:&lt;/span&gt;                 rareFields = FormatterServices.GetUninitializedObject(rareFieldsField.FieldType);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum47"&gt;  47:&lt;/span&gt;                 rareFieldsField.SetValue(occasionalFields, rareFields);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum48"&gt;  48:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum49"&gt;  49:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum50"&gt;  50:&lt;/span&gt;             FieldInfo adapterField = rareFields.GetType().GetField(&lt;span style="color: #006080"&gt;&amp;quot;Adapter&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum51"&gt;  51:&lt;/span&gt;             ControlAdapter adapter = adapterField.GetValue(rareFields) &lt;span style="color: #0000ff"&gt;as&lt;/span&gt; ControlAdapter;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum52"&gt;  52:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum53"&gt;  53:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;return&lt;/span&gt; (adapter);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum54"&gt;  54:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum55"&gt;  55:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum56"&gt;  56:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; &lt;span style="color: #0000ff"&gt;void&lt;/span&gt; setControlAdapter(Control control, ControlAdapter controlAdapter)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum57"&gt;  57:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum58"&gt;  58:&lt;/span&gt;             Object occasionalFields = occasionalFieldsField.GetValue(control);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum59"&gt;  59:&lt;/span&gt;             FieldInfo rareFieldsField = occasionalFields.GetType().GetField(&lt;span style="color: #006080"&gt;&amp;quot;RareFields&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum60"&gt;  60:&lt;/span&gt;             Object rareFields = rareFieldsField.GetValue(occasionalFields);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum61"&gt;  61:&lt;/span&gt;             FieldInfo adapterField = rareFields.GetType().GetField(&lt;span style="color: #006080"&gt;&amp;quot;Adapter&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum62"&gt;  62:&lt;/span&gt;             adapterField.SetValue(rareFields, controlAdapter);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum63"&gt;  63:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum64"&gt;  64:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum65"&gt;  65:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;internal&lt;/span&gt; &lt;span style="color: #0000ff"&gt;void&lt;/span&gt; RaiseOutputEvent(OutputEventArgs e)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum66"&gt;  66:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum67"&gt;  67:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Output != &lt;span style="color: #0000ff"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum68"&gt;  68:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum69"&gt;  69:&lt;/span&gt;                 &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Output(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;, e);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum70"&gt;  70:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum71"&gt;  71:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum72"&gt;  72:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum73"&gt;  73:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;protected&lt;/span&gt; &lt;span style="color: #0000ff"&gt;override&lt;/span&gt; &lt;span style="color: #0000ff"&gt;void&lt;/span&gt; OnPreRender(EventArgs e)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum74"&gt;  74:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum75"&gt;  75:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; ((&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Enabled == &lt;span style="color: #0000ff"&gt;true&lt;/span&gt;) &amp;amp;&amp;amp; (String.IsNullOrWhiteSpace(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.TargetControlID) == &lt;span style="color: #0000ff"&gt;false&lt;/span&gt;))&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum76"&gt;  76:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum77"&gt;  77:&lt;/span&gt;                 Control control = &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.FindControl(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.TargetControlID);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum78"&gt;  78:&lt;/span&gt;                 ControlAdapter controlAdapter = &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.getControlAdapter(control);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum79"&gt;  79:&lt;/span&gt;                 OutputAdapterControlAdapter newAdapter = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; OutputAdapterControlAdapter(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;, controlAdapter, control, &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.XslPath);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum80"&gt;  80:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum81"&gt;  81:&lt;/span&gt;                 &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.setControlAdapter(control, newAdapter);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum82"&gt;  82:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum83"&gt;  83:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum84"&gt;  84:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;base&lt;/span&gt;.OnPreRender(e);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum85"&gt;  85:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum86"&gt;  86:&lt;/span&gt;     }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum87"&gt;  87:&lt;/span&gt; }&lt;/pre&gt;
&lt;!--CRLF--&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;And the code for the control adapter is:&lt;/p&gt;

&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
  &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;
    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;namespace&lt;/span&gt; WebApplication1&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt; {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; &lt;span style="color: #0000ff"&gt;class&lt;/span&gt; OutputAdapterControlAdapter : ControlAdapter&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;     {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; &lt;span style="color: #0000ff"&gt;static&lt;/span&gt; &lt;span style="color: #0000ff"&gt;readonly&lt;/span&gt; FieldInfo controlField = &lt;span style="color: #0000ff"&gt;typeof&lt;/span&gt;(ControlAdapter).GetField(&lt;span style="color: #006080"&gt;&amp;quot;_control&amp;quot;&lt;/span&gt;, BindingFlags.NonPublic | BindingFlags.Instance);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum6"&gt;   6:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; &lt;span style="color: #0000ff"&gt;static&lt;/span&gt; &lt;span style="color: #0000ff"&gt;readonly&lt;/span&gt; MethodInfo controlRenderMethod = &lt;span style="color: #0000ff"&gt;typeof&lt;/span&gt;(Control).GetMethod(&lt;span style="color: #006080"&gt;&amp;quot;Render&amp;quot;&lt;/span&gt;, BindingFlags.NonPublic | BindingFlags.Instance);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum7"&gt;   7:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; &lt;span style="color: #0000ff"&gt;static&lt;/span&gt; &lt;span style="color: #0000ff"&gt;readonly&lt;/span&gt; MethodInfo controlAdapterRenderMethod = &lt;span style="color: #0000ff"&gt;typeof&lt;/span&gt;(ControlAdapter).GetMethod(&lt;span style="color: #006080"&gt;&amp;quot;Render&amp;quot;&lt;/span&gt;, BindingFlags.NonPublic | BindingFlags.Instance);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum8"&gt;   8:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum9"&gt;   9:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; OutputAdapterControlAdapter(OutputAdapterControl outputControl, ControlAdapter original, Control control, String xslPath)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum10"&gt;  10:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum11"&gt;  11:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.OutputControl = outputControl;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum12"&gt;  12:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Original = original;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum13"&gt;  13:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.XslPath = xslPath;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum14"&gt;  14:&lt;/span&gt;             controlField.SetValue(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;, control);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum15"&gt;  15:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum16"&gt;  16:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum17"&gt;  17:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;protected&lt;/span&gt; OutputAdapterControl OutputControl&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum18"&gt;  18:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum19"&gt;  19:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum20"&gt;  20:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum21"&gt;  21:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum22"&gt;  22:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum23"&gt;  23:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;protected&lt;/span&gt; String XslPath&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum24"&gt;  24:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum25"&gt;  25:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum26"&gt;  26:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum27"&gt;  27:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum28"&gt;  28:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum29"&gt;  29:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;protected&lt;/span&gt; ControlAdapter Original&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum30"&gt;  30:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum31"&gt;  31:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum32"&gt;  32:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;private&lt;/span&gt; set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum33"&gt;  33:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum34"&gt;  34:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum35"&gt;  35:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;protected&lt;/span&gt; &lt;span style="color: #0000ff"&gt;override&lt;/span&gt; &lt;span style="color: #0000ff"&gt;void&lt;/span&gt; Render(HtmlTextWriter writer)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum36"&gt;  36:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum37"&gt;  37:&lt;/span&gt;             StringBuilder builder = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; StringBuilder();&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum38"&gt;  38:&lt;/span&gt;             HtmlTextWriter tempWriter = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; HtmlTextWriter(&lt;span style="color: #0000ff"&gt;new&lt;/span&gt; StringWriter(builder));&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum39"&gt;  39:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum40"&gt;  40:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Original != &lt;span style="color: #0000ff"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum41"&gt;  41:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum42"&gt;  42:&lt;/span&gt;                 controlAdapterRenderMethod.Invoke(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Original, &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; Object[] { tempWriter });&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum43"&gt;  43:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum44"&gt;  44:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;else&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum45"&gt;  45:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum46"&gt;  46:&lt;/span&gt;                 controlRenderMethod.Invoke(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.Control, &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; Object[] { tempWriter });&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum47"&gt;  47:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum48"&gt;  48:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum49"&gt;  49:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (String.IsNullOrWhiteSpace(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.XslPath) == &lt;span style="color: #0000ff"&gt;false&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum50"&gt;  50:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum51"&gt;  51:&lt;/span&gt;                 String path = HttpContext.Current.Server.MapPath(&lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.XslPath);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum52"&gt;  52:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum53"&gt;  53:&lt;/span&gt;                 XmlDocument xml = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; XmlDocument();&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum54"&gt;  54:&lt;/span&gt;                 xml.LoadXml(builder.ToString());&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum55"&gt;  55:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum56"&gt;  56:&lt;/span&gt;                 builder.Clear();&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum57"&gt;  57:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum58"&gt;  58:&lt;/span&gt;                 XslCompiledTransform xsl = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; XslCompiledTransform();&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum59"&gt;  59:&lt;/span&gt;                 xsl.Load(path);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum60"&gt;  60:&lt;/span&gt;                 xsl.Transform(xml, &lt;span style="color: #0000ff"&gt;null&lt;/span&gt;, tempWriter);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum61"&gt;  61:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum62"&gt;  62:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum63"&gt;  63:&lt;/span&gt;             OutputEventArgs e = &lt;span style="color: #0000ff"&gt;new&lt;/span&gt; OutputEventArgs() { Html = builder.ToString() };&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum64"&gt;  64:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum65"&gt;  65:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;this&lt;/span&gt;.OutputControl.RaiseOutputEvent(e);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum66"&gt;  66:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum67"&gt;  67:&lt;/span&gt;             &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (e.Html != builder.ToString())&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum68"&gt;  68:&lt;/span&gt;             {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum69"&gt;  69:&lt;/span&gt;                 builder.Clear();&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum70"&gt;  70:&lt;/span&gt;                 builder.Append(e.Html);&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum71"&gt;  71:&lt;/span&gt;             }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum72"&gt;  72:&lt;/span&gt;&amp;#160; &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum73"&gt;  73:&lt;/span&gt;             writer.Write(builder.ToString());&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum74"&gt;  74:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum75"&gt;  75:&lt;/span&gt;     }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum76"&gt;  76:&lt;/span&gt; }&lt;/pre&gt;
&lt;!--CRLF--&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;Finally there’s the event argument:&lt;/p&gt;

&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
  &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;
    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;namespace&lt;/span&gt; WebApplication1&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt; {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;     [Serializable]&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt;     &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; &lt;span style="color: #0000ff"&gt;class&lt;/span&gt; OutputEventArgs : EventArgs&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum5"&gt;   5:&lt;/span&gt;     {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum6"&gt;   6:&lt;/span&gt;         &lt;span style="color: #0000ff"&gt;public&lt;/span&gt; String Html&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum7"&gt;   7:&lt;/span&gt;         {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum8"&gt;   8:&lt;/span&gt;             get;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum9"&gt;   9:&lt;/span&gt;             set;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum10"&gt;  10:&lt;/span&gt;         }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum11"&gt;  11:&lt;/span&gt;     }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum12"&gt;  12:&lt;/span&gt; }&lt;/pre&gt;
&lt;!--CRLF--&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;And a sample event handler:&lt;/p&gt;

&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
  &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;
    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum1"&gt;   1:&lt;/span&gt; &lt;span style="color: #0000ff"&gt;protected&lt;/span&gt; &lt;span style="color: #0000ff"&gt;void&lt;/span&gt; OnOutput(&lt;span style="color: #0000ff"&gt;object&lt;/span&gt; sender, OutputEventArgs e)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum2"&gt;   2:&lt;/span&gt; {&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum3"&gt;   3:&lt;/span&gt;     e.Html = e.Html.ToUpper();&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #606060" id="lnum4"&gt;   4:&lt;/span&gt; }&lt;/pre&gt;
&lt;!--CRLF--&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;Please note that this relies heavily on reflection, and, for that matter, will only work with ASP.NET 4.0. It can be made to work with ASP.NET 2/3.5, but you will have to change the code to get to the stored control adapter in the &lt;a title="Control Class" href="http://msdn2.microsoft.com/983zwx2h.aspx"&gt;Control&lt;/a&gt; class. Thanks to &lt;a href="http://exceptionalcode.wordpress.com/" target="_blank"&gt;João Angelo&lt;/a&gt; for reminding me of that!&lt;/p&gt;

&lt;p&gt;If you look at it carefully, you will see that, if an XSL transformation file is specified, the control adapter will use it to transform the output of the target control. Either way, if an event handler is registered, it will raise the event, passing in the event argument the HTML generated by the target control, possibly modified by the XSL transformation. In the event handler, all you have to do is change the &lt;strong&gt;Html&lt;/strong&gt; property of the event argument.&lt;/p&gt;

&lt;p&gt;Let me know if this helps in some way, and have fun!&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8281876" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/ricardoperes/archive/tags/.NET/default.aspx">.NET</category><category domain="http://weblogs.asp.net/ricardoperes/archive/tags/.NET+4/default.aspx">.NET 4</category><category domain="http://weblogs.asp.net/ricardoperes/archive/tags/ASP.NET/default.aspx">ASP.NET</category><category domain="http://weblogs.asp.net/ricardoperes/archive/tags/Web/default.aspx">Web</category></item><item><title>Scaling ASP.NET websites from thousands to millions–LIDNUG</title><link>http://weblogs.asp.net/omarzabir/archive/2012/02/04/scaling-asp-net-websites-from-thousands-to-millions-lidnug.aspx</link><pubDate>Sat, 04 Feb 2012 11:01:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8281470</guid><dc:creator>oazabir</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Here’s the recent presentation made on LIDNUG on scaling ASP.NET websites from thousands to millions of users. &lt;/p&gt;  &lt;div style="padding-bottom: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; float: none; padding-top: 0px" id="scid:5737277B-5D6D-4f48-ABFC-DD9C333F4C5D:207ae8d5-9cc1-4246-85c6-13a438596d79" class="wlWriterEditableSmartContent"&gt;&lt;div&gt;&lt;a href="http://www.youtube.com/watch?v=wHdvL4irsiQ&amp;amp;#t=02m04s&amp;amp;ap=%2526fmt%3D18?" target="_new"&gt;&lt;img src="http://weblogs.asp.net/blogs/omarzabir/videoa1dbc9c58e36_40F4C3CF.jpg" style="border-style: none" galleryimg="no" alt=""&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="width:448px;clear:both;font-size:.8em"&gt;Scaling ASP.NET websites from thousands to millions of users by Omar AL Zabir&lt;/div&gt;&lt;/div&gt;  &lt;p&gt;Here’re the slides.&lt;/p&gt;  &lt;div style="width: 425px" id="__ss_11418912"&gt;&lt;strong style="margin: 12px 0px 4px; display: block"&gt;&lt;a title="Scaling asp.net websites to millions of users" href="http://www.slideshare.net/oazabir/scaling-aspnet-websites-to-millions-of-users" target="_blank"&gt;Scaling asp.net websites to millions of users&lt;/a&gt;&lt;/strong&gt; &lt;iframe height="355" marginheight="0" src="http://www.slideshare.net/slideshow/embed_code/11418912" frameborder="0" width="425" marginwidth="0" scrolling="no"&gt;&lt;/iframe&gt;&lt;/div&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8281470" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/omarzabir/archive/tags/asp.net/default.aspx">asp.net</category><category domain="http://weblogs.asp.net/omarzabir/archive/tags/LINQ/default.aspx">LINQ</category><category domain="http://weblogs.asp.net/omarzabir/archive/tags/performance/default.aspx">performance</category><category domain="http://weblogs.asp.net/omarzabir/archive/tags/production/default.aspx">production</category><category domain="http://weblogs.asp.net/omarzabir/archive/tags/WCF/default.aspx">WCF</category><category domain="http://weblogs.asp.net/omarzabir/archive/tags/Web+Services/default.aspx">Web Services</category></item><item><title>Flush IIS HTTP and FTP Logs to Disk</title><link>http://weblogs.asp.net/owscott/archive/2012/02/03/flush-http-and-ftp-logs-in-iis.aspx</link><pubDate>Sat, 04 Feb 2012 04:11:13 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8280314</guid><dc:creator>OWScott</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;Today I wanted to find a way to flush the IIS FTP logs on-demand.&amp;#160; The logs for IIS FTP flush to disk every 6 minutes, and the HTTP logs every 1 minute (or 64kb).&amp;#160; This can make troubleshooting difficult when you don’t receive immediate access to the latest log data.&lt;/p&gt;  &lt;p&gt;After looking everywhere I could think of, from search engine searches to perusing through the &lt;a href="http://dotnetslackers.com/articles/iis/Mastering-IIS-Understanding-the-Schema-Week-19.aspx" target="_blank"&gt;IIS schema files&lt;/a&gt;, I figured I had better go to the source and ask &lt;a href="http://blogs.msdn.com/b/robert_mcmurray" target="_blank"&gt;Robert McMurray&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Sure enough, Robert had the answer and even &lt;a href="http://blogs.msdn.com/b/robert_mcmurray/archive/2012/02/03/programmatically-flushing-ftp-logs.aspx" target="_blank"&gt;wrote a blog post&lt;/a&gt; in response to my question with code examples for four scripting/programming languages (C#, VB.NET, JavaScript, VbScript).&lt;/p&gt;  &lt;p&gt;There is not a netsh or appcmd solution though, so the scripting or programming options are the way to do it.&amp;#160; Actually, you can also flush the logs by restarting the Microsoft FTP Service (ftpsvc) but, as you would assume, it will impact currently active FTP sessions.&lt;/p&gt;  &lt;p&gt;This blog post serves three purposes.&amp;#160; &lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;It’s a reference pointing to Robert’s examples &lt;/li&gt;    &lt;li&gt;I’ll include how to do the same for the HTTP logs &lt;/li&gt;    &lt;li&gt;I’ll provide a PowerShell example which I based on Robert’s examples &lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;1. The reference is mentioned above already, but to give me something useful to write in this paragraph, I’ll include it again. &lt;a href="http://blogs.msdn.com/b/robert_mcmurray/archive/2012/02/03/programmatically-flushing-ftp-logs.aspx" target="_blank"&gt;Programmatically Flushing FTP Logs&lt;/a&gt;. &lt;/p&gt;  &lt;p&gt;2. For HTTP there is a method to flush the logs using netsh.&lt;/p&gt;  &lt;pre class="csharpcode"&gt;netsh http flush logbuffer&lt;/pre&gt;
&lt;style type="text/css"&gt;

.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; }&lt;/style&gt;

&lt;p&gt;This will immediately flush the HTTP logs for all sites.&lt;/p&gt;

&lt;p&gt;3. The FTP logs can be done from PowerShell too.&amp;#160; Here’s a script which is the PowerShell equivalent of Robert’s examples.&amp;#160; Just update $siteName, or pass it as a parameter to the script.&lt;/p&gt;

&lt;div style="border-bottom: silver 1px solid; text-align: left; border-left: silver 1px solid; padding-bottom: 4px; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; padding-left: 4px; width: 97.5%; padding-right: 4px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; border-top: silver 1px solid; cursor: text; border-right: silver 1px solid; padding-top: 4px" id="codeSnippetWrapper"&gt;
  &lt;div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px" id="codeSnippet"&gt;
    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;Param($siteName = &lt;span style="color: #006080"&gt;&amp;quot;Default Web Site&amp;quot;&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&amp;#160;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;#Get MWA ServerManager&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;[System.Reflection.Assembly]::LoadFrom( &lt;span style="color: #006080"&gt;&amp;quot;C:\windows\system32\inetsrv\Microsoft.Web.Administration.dll&amp;quot;&lt;/span&gt; ) | Out-Null&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;$serverManager = new-object Microsoft.Web.Administration.ServerManager &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&amp;#160;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;$config = $serverManager.GetApplicationHostConfiguration()&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&amp;#160;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;#Get Sites Collection&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;$sitesSection = $config.GetSection(&lt;span style="color: #006080"&gt;&amp;quot;system.applicationHost/sites&amp;quot;&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;$sitesCollection = $sitesSection.GetCollection()&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&amp;#160;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;#Find Site&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #0000ff"&gt;foreach&lt;/span&gt; ($item &lt;span style="color: #0000ff"&gt;in&lt;/span&gt; $sitesCollection){&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&amp;#160;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;    &lt;span style="color: #0000ff"&gt;if&lt;/span&gt; ($item.Attributes.Item($elementTagName).Value &lt;span style="color: #cc6633"&gt;-eq&lt;/span&gt; $siteName){&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;        $site = $item&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;    }&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;}&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;#Validation&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #0000ff"&gt;if&lt;/span&gt; ($site &lt;span style="color: #cc6633"&gt;-eq&lt;/span&gt; $null) { &lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;    Write-Host &lt;span style="color: #006080"&gt;&amp;quot;Site '$siteName' not found&amp;quot;&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;    &lt;span style="color: #0000ff"&gt;return&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;}&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #0000ff"&gt;if&lt;/span&gt; (!($ftpServer.ChildElements.Count)){&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;    Write-Host &lt;span style="color: #006080"&gt;&amp;quot;Site '$siteName' does not have FTP bindings set&amp;quot;&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;    &lt;span style="color: #0000ff"&gt;return&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;}&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&amp;#160;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;&lt;span style="color: #008000"&gt;#Flush the Logs&lt;/span&gt;&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: white; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;$ftpServer = $site.ChildElements.Item(&lt;span style="color: #006080"&gt;&amp;quot;ftpServer&amp;quot;&lt;/span&gt;)&lt;/pre&gt;
&lt;!--CRLF--&gt;

    &lt;pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; background-color: #f4f4f4; margin: 0em; border-left-style: none; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &amp;#39;Courier New&amp;#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; border-right-style: none; font-size: 8pt; overflow: visible; padding-top: 0px"&gt;$ftpServer.Methods.Item(&lt;span style="color: #006080"&gt;&amp;quot;FlushLog&amp;quot;&lt;/span&gt;).CreateInstance().Execute()&lt;/pre&gt;
&lt;!--CRLF--&gt;&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;I hope one of these programming/scripting options come in handy for times when you want immediate access to the latest FTP log data.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8280314" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/owscott/archive/tags/FTP/default.aspx">FTP</category><category domain="http://weblogs.asp.net/owscott/archive/tags/IIS/default.aspx">IIS</category><category domain="http://weblogs.asp.net/owscott/archive/tags/IIS7/default.aspx">IIS7</category></item><item><title>Flush IIS HTTP and FTP Logs to Disk</title><link>http://blogs.iis.net/owscott/archive/2012/02/03/flush-iis-http-and-ftp-logs-to-disk.aspx</link><pubDate>Sat, 04 Feb 2012 04:11:13 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:8280461</guid><dc:creator>The Official Microsoft IIS Site</dc:creator><slash:comments>0</slash:comments><description>Today I wanted to find a way to flush the IIS FTP logs on-demand.&amp;#160; The logs for IIS FTP flush to disk every 6 minutes, and the HTTP logs every 1 minute (or 64kb).&amp;#160; This can make troubleshooting difficult when you don’t receive immediate access Read More......( read more ) Read More......(&lt;a href="http://blogs.iis.net/owscott/archive/2012/02/03/flush-iis-http-and-ftp-logs-to-disk.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8280461" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/iis/archive/tags/FTP/default.aspx">FTP</category><category domain="http://weblogs.asp.net/iis/archive/tags/IIS/default.aspx">IIS</category><category domain="http://weblogs.asp.net/iis/archive/tags/IIS7/default.aspx">IIS7</category></item></channel></rss>
