<feed version="0.3" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns="http://purl.org/atom/ns#" xml:lang="en-US"><title>Rick Strahl</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/default.aspx" /><tagline type="text/html">&lt;outline&gt;
 &lt;outline category="Main" xmlUrl="http://west-wind.com/weblog/Rss.aspx"&gt;
 &lt;/outline&gt;
 &lt;outline category="Html" xmlUrl="http://west-wind.com/weblog/Rss.aspx?CategoryID=17"&gt;
 &lt;/outline&gt;
&lt;outline category="asp.net" xmlUrl="http://west-wind.com/weblog/category/13.aspx"&gt;
 &lt;/outline&gt;
&lt;outline category="Personal" xmlUrl="http://west-wind.com/weblog/category/9.aspx"&gt;
 &lt;/outline&gt;
&lt;/outline&gt;</tagline><id>http://thedotnet.com/blogs/rick_strahl/default.aspx</id><author><url>http://thedotnet.com/blogs/rick_strahl/default.aspx</url></author><generator url="http://communityserver.org" version="1.1.0.50615">Community Server</generator><modified>2005-08-01T01:08:00Z</modified><entry><title>Atlas to carry the ASP.NET World - take 1</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/10/02/614931.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:614931</id><created>2005-10-02T19:54:00Z</created><content type="text/html" mode="escaped">&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;At the Professional Developer Conference (PDC) in September Microsoft offered a first glimpse at its &lt;?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /&gt;&lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; (Asynchronous JavaScript and XML) strategy which has been given the codename of Atlas. As you probably are aware of, &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; is the current over-hyped buzzword in Web Development. It promises the ability to write richer browser applications and retrieve data from the server to update the content of the current page without having to completely repost the page to the Web Server. The advantage of this type of application is that it provides more efficient usage of the bandwidth available to Web applications and &amp;#8211; in many cases &amp;#8211; provides a smoother, more responsive and non-flashing user interface that Web applications are typically not known for. On the flipside &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; relies on more recent browsers and fairly extensive use of client side script code to provide the rich interaction between the browser and server.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;The hype over &lt;st1:City w:st="on"&gt;AJAX&lt;/st1:City&gt; aside, Microsoft&amp;#8217;s first effort in the &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; space was a disappointing one. ASP.NET 2.0 will ship with a technology called &lt;A href="http://www.asptoday.com/Content.aspx?id=2381"&gt;Script Callbacks&lt;/A&gt; that is native ASP.NET. Script Callbacks is a simple and quirky, interface based implementation of page callbacks that are entirely bound to the ASP.NET page lifecycle. While functional, the model used in this architecture is both limited and implemented in a way that makes using it rather cumbersome and unnatural. Microsoft developed this technology for internal use early in the ASP.NET 2.0 cycle before &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; became fashionable. It&amp;#8217;s used internally in several of the ASP.NET server controls like the GridView and TreeView to support client side updates of the data displayed. &lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;If you are looking to do &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; style development with ASP.NET 1.1 or 2.0 today there are other possibly easier and more fully implemented solutions available from the community. I personally like &lt;A href="http://jason.diamond.name/weblog/2005/07/06/my-ajax-dot-net-library"&gt;Jason Diamond&amp;#8217;s My Ajax.Net&lt;/A&gt; and have used it quite a bit internally. Another popular library is &lt;A href="http://ajax.schwarz-interactive.de/csharpsample/default.aspx"&gt;Michael Schwarz&amp;#8217;s Ajax.NET&lt;/A&gt; which is probably the most used &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; implementation on .NET today. Both are open source and come with source code and more importantly both are easy to use and provide simplicity for the 90% use case scenarios and they work with ASP.NET 1.1 so you can use it in all of your ASP.NET applications.&lt;/P&gt;
&lt;H3 style="MARGIN: 12pt 0in 3pt"&gt;&lt;FONT color=#000080 size=2&gt;Atlas to the rescue&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Not to be outdone, Microsoft entered the &lt;st1:place w:st="on"&gt;&lt;st1:City w:st="on"&gt;AJAX&lt;/st1:City&gt;&lt;/st1:place&gt; space for real with the announcement of the &lt;A href="http://atlas.asp.net/"&gt;Atlas Project&lt;/A&gt; just a few weeks before PDC and officially previewed the technology at the conference. As expected Atlas is a very ambitious project and covers a huge range of features that cover a variety of approaches to implementing &lt;st1:place w:st="on"&gt;&lt;st1:City w:st="on"&gt;AJAX&lt;/st1:City&gt;&lt;/st1:place&gt; style applications. Atlas is slated to be shipped as an add-on to ASP.NET 2.0 sometime in 2006, so it&amp;#8217;s still a ways off. One nice thing announced is that Microsoft is planning on shipping Atlas outside of the regular ASP.NET product cycle initially so the product can rev much more quickly than a full ASP.NET cycle. Atlas likely will ship as an add-on assembly (or assemblies) plus a script library that can simply be added to an application. At a later point in time it&amp;#8217;s likely that tool integration with Visual Studio will take place resulting in a tighter binding to the core ASP.NET platform.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;So what does Atlas bring to the party? A lot of things actually, but it&amp;#8217;s important to understand that not all of the features of this overwhelming library are necessary to start doing &lt;st1:place w:st="on"&gt;&lt;st1:City w:st="on"&gt;AJAX&lt;/st1:City&gt;&lt;/st1:place&gt; style development. Here are the some of the core features:&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;st1:place w:st="on"&gt;&lt;st1:PlaceName w:st="on"&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;Web&lt;/B&gt;&lt;/st1:PlaceName&gt;&lt;B style="mso-bidi-font-weight: normal"&gt; &lt;st1:PlaceName w:st="on"&gt;Service&lt;/st1:PlaceName&gt; &lt;st1:PlaceName w:st="on"&gt;Connector&lt;/st1:PlaceName&gt; &lt;st1:PlaceType w:st="on"&gt;Bridge&lt;/st1:PlaceType&gt;&lt;/B&gt;&lt;/st1:place&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;One of the core features of the Atlas framework is the ability to bring down data to the browser quite easily by using a new Web Service interface that gets hooked by the Atlas framework. This special HTTP handler interface essentially allows an Atlas client application to communicate with a .NET Web Service using the JSON serialization format. JSON is a JavaScript compatible, light weight serialization format that encodes any type including complex type into a string that can be evaluated in JavaScript and provide a type reference. This simple interface allows you to take advantage of existing Web Services &amp;#8211; or new ones &amp;#8211; to access server side logic from the client applications without all of the overhead that SOAP entails. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;This interface is two-way, so you can receive data from a Web Service and you can send it back up to the server using the same mechanism. Atlas can serialize and deserialize the JSON format both on the client and server. To facilitate this process the Atlas client framework includes the infrastructure to manage type information which becomes part of the JSON serialization strings that travel over the wire. What&amp;#8217;s really nice here is that in combination with the client side script framework you can return many common types from the server and use them easily on the client. For example, you can return arrays, collections, data tables and data rows and the client framework will provide a CLR like client implementation of that type. Custom types are also supported.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;This deceptively simple implementation provides a lot of power to existing applications that might not even want to take advantage of all that the Atlas framework has to offer. This is a close match in functionality to the tools I mentioned earlier only more closely integrated with standard ASP.NET practices. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Web Service methods can be implemented both in a separate Web Service class or can be called directly in the current page. One interesting feature of the page based WebMethod call is that all of the page&amp;#8217;s POST data gets written back to the server and the callback with full support for the page lifecycle including access to updated control values and ViewState. The full Web Service interface can work with current ASMX implementations or with Indigo services.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Personally I prefer the external Web Service approach as it promotes better separation of the UI logic and the data service functionality. Using the Web Service also means that the data is much more reusable. For example, if you end up building a true Smart Client application it will be able to consume the exact same data using a standard Web Service from exactly the same code base.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;In some preliminary tests I found this mechanism in combination with the rich type support very powerful. The ability to easily pass complex types and collections of types from the server to the client and back makes it quite easy to update the user interface, modify data and send it back &lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;without having to resort to writing complex string encoding schemes to pass the data around. For interfacing wit business data this mechanism really provides clean separation of the UI and business layers. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;Client Side JavaScript Framework&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;As mentioned above, Atlas provides a rich client framework that provides many of the core services required by other parts of Atlas. Atlas uses a layered client architecture of services provided by the framework. Most of these layers are internally used such as the rendering features for controls, the browser compatibility layer and the network layer used to send requests back and forth.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;BR&gt;But one layer you&amp;#8217;re likely to see a lot of in your client applications is the Core framework and Base Class Library which provides a small subset of .NET CLR and BCL functionality on the client side. The Core functionality provides a number of language features that are interesting. There&amp;#8217;s namespace support and type registration to provide a simulacrum of typed JavaScript variables. Perhaps most interesting is the client-side BCL implementation which provides support for many common basic classes and structures that are used in .NET development. This means that the code you write on the client script end, looks a lot closer to .NET code than it currently does even if some constructs are bound to quirky JavaScript language features.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;Client Side and Server Side Controls and &amp;#8216;Atlas Script Markup&amp;#8217;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;In addition to the framework Atlas also provides a core set of controls that provide browser independent implementations of many common ASP.NET controls. What this powerful feature buys is an abstracted control model that alleviates the developer&amp;#8217;s need to fully understand the nuances of every browser running on a client. If you&amp;#8217;ve ever done any sort of UI development with client side JavaScript you know that the syntax and object models of various controls varies ever so slightly and these client side implemented custom controls alleviate the need to have to code to these browser specific nuances. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;It&amp;#8217;s hard to tell right now how this works, but the Atlas framework uses these controls internally to manage the browser independent rendering of script code. Examples of this stuff have really not been provided but it was shown by &lt;A href="http://www.nikhilk.net/"&gt;Nikhil Korhan&lt;/A&gt; in the &lt;A href="http://www.nikhilk.net/Entry.aspx?id=92"&gt;Server Control talk at PDC&lt;/A&gt;. At the moment these controls are internally used by the Atlas Server Controls and the &amp;#8216;script markup&amp;#8217; they generate in the client side HTML page. Atlas basically uses declarative script tags to drive functionality through behavior attributes. For example, you tell the control to invoke a method on another control (or data control) to retrieve the data, or set the value of a given property.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;The script markup is interesting in that server controls generate their declarative markup to the client as is within an embedded &amp;lt;script type="text/xml-script"&amp;gt; tag. The Atlas client framework then evaluates this script markup dynamically to generate the actual page behavior and layout. In other words, unlike server controls, these controls use the client side controls and framework to manage the parsing and even code generation at runtime in the browser. This takes a moment to grasp. The reasoning behind this client side parsing and execution seems to be to avoid having to generate reams and reams of JavaScript code and injecting it into the page before sending it from the server. By doing it on the client this markup functionality can be easily added to any page and can stay relatively small describing the actions of the page.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Microsoft seems to be emphasizing this declarative style of programming, but that doesn&amp;#8217;t mean that script code driven logic is not available. You are absolutely able to drill down to the script level and write the control code and logic yourself. If you do you can take advantage of the control architecture and BCL implementation so you get much richer client side functionality. But keep in mind that some of these features are hacked together around the limitations of JavaScript, like the Type subsystem and Object Oriented featured in general. It&amp;#8217;s still JavaScript. Bend it as they might, Microsoft is sticking to a pure JavaScript implementation.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;This is all pretty vague at this point as there&amp;#8217;s zero documentation, but it shows the direction that Microsoft is headed. The idea for the markup code is that rather than writing potentially browser specific JavaScript code you write declarative markup that the Atlas framework then renders into control code and script code that is dynamically generated and executed at runtime. &lt;A href="http://weblogs.asp.net/bleroy/"&gt;Bertrand LeRoy&lt;/A&gt; has a &lt;A href="http://weblogs.asp.net/bleroy/archive/2005/09/20/425698.aspx"&gt;nice example&lt;/A&gt; that demonstrates the server control/markup syntax a lot better than the simplistic PDC labs. In that example, you can get a pretty good idea of what markup will be capable of by providing a very UI centric interface.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;While I think that this is a noble goal, I personally have many misgivings about this declarative model, because it&amp;#8217;s completely UI centric. You basically map a Web Service (or other datasource) to a property or method of another control, but there&amp;#8217;s very little room for custom code that is almost certainly going to be required in addition to 1 &amp;#8211; 1 mappings. In addition the markup model introduces yet another &amp;#8216;scripting&amp;#8217; layer into your applications with yet another different markup syntax. However, all of the markup actually gets translated into JavaScript that eventually executes.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;The functionality of this markup reminds of Ruby on Rails to some degree, and it&amp;#8217;s a model that I dislike vehemently. I don&amp;#8217;t trust code that is handled for me to serve all of my needs and this has the beginnings of a high level description language that doesn&amp;#8217;t sit well with me. I have to admit I had similar misgivings about the template driven approach that ASP.NET controls use, and eventually I came around to it once I understood fully what you can and can&amp;#8217;t do with that approach. I expect the the same will apply here.&lt;/P&gt;
&lt;H3 style="MARGIN: 12pt 0in 3pt"&gt;&lt;FONT color=#000080 size=2&gt;The Good, the Bad and the Ugly&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Looking at Atlas in this early stage is a mixed bag. As with many of these types of previews the documentation is nearly non-existent, beyond a few hands-on labs which give a cross section of the features available. The labs are actually quite good at demonstrating a number of common scenarios, from basic to the cool factor type. But, the labs are not a good substitute for documentation. They only address a very minimalist subset of the capabilities and provide absolutely no insight into how things work behind the scenes which is this point would be beneficial. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;If you want to know how things work your only avenue is to open up the JavaScript libraries with their bunched up, line-feed removed code and dig through the spaghetti code that is JavaScript even at its best. Most of the meat of Atlas is in the JavaScript. For the server side code you&amp;#8217;ll need to dig out your copy of &lt;A href="http://www.aisto.com/roeder/dotnet/"&gt;Reflector&lt;/A&gt; and start digging into the binary bits. Looking through all of this you&amp;#8217;ll find that there&amp;#8217;s a lot of implementation code &amp;#8211; Atlas has been a while coming at Microsoft.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;I spent some time to go through the labs and that worked just fine, but as soon as I started going off the beaten path a number of things started breaking. For example, the Web Service functionality started breaking on even some simple custom types I set up. There&amp;#8217;s no exception handling in the Web Service behavior so if anything goes wrong on the server, or you need to notify the client of a non-success result via a SOAPException, the server spits back HTML instead of an Exception or other object that includes an Exception. So even some of the simple steps failed outright. Working on from the labs and trying to use the server control markup to fire custom code also proved difficult &amp;#8211; basically I was stopped dead in my tracks almost at every corner due to lack of documentation. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Playing with Atlas at the moment is beyond even bleeding edge technology. Don&amp;#8217;t waste your time with it unless you&amp;#8217;re willing to dig into the code base and find your own &amp;#8216;documentation&amp;#8217; there.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;But this is understandable from Microsoft&amp;#8217;s point of view. It&amp;#8217;s meant as a very early glimpse at what Microsoft is doing. I don&amp;#8217;t think there&amp;#8217;s any hope of doing anything useful with this technology at this time other than check it out and give Microsoft feedback on direction. One thing is for sure: this stuff is likely to change drastically, so don&amp;#8217;t get too familiar with what&amp;#8217;s there today.&lt;/P&gt;
&lt;H3 style="MARGIN: 12pt 0in 3pt"&gt;&lt;FONT color=#000080 size=2&gt;Pain Factor: Client Side Scripting&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Atlas provides a lot of technology and functionality at the library level, but it doesn&amp;#8217;t provide any new tool support at least not at the moment. I would argue that the biggest detriment to efficient client side and &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; development is the lack of decent tools to debug your client side script code. Writing client script code is easily 4 to 5 times slower (for me at least) than it is to write the equivalent server side code. Lack of Intellisense, compilation, and the mere lack of decent documentation for the various object models make all of this difficult. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Microsoft is addressing some of these issues with the client side libraries and bringing a more consistent object model to client side code so via the client side markup. By using these client side libraries Microsoft is able to abstract away some of the browser compatibility issues and providing you as the developer with a more consistent single access model to code against. This is an important step in the right direction, but tool support is absolutely required if we are to build applications that will rely on an increasing amount of client side logic.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Client side debugging is not being addressed at the moment. That support is something likely to come in future versions of Visual Studio &lt;/P&gt;
&lt;H3 style="MARGIN: 12pt 0in 3pt"&gt;&lt;FONT color=#000080 size=2&gt;Smart Client and Thin Client &amp;#8211; No Contest, Yet!&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;There are some interesting issues that Atlas brings up. It&amp;#8217;s obvious to see that Microsoft has heavily invested in Atlas by the sheer breadth that this toolkit attempts to address. With all the talk about Windows Vista and Avalon &amp;#8211; uh, Windows Presentation Framework (WPF) and the return of the Smart Client, it&amp;#8217;s also clear that Microsoft sees the importance of Web based applications and continues to provide tools to build rich applications for this platform. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Try as we might, rich client advances to date have had very little impact on how Web applications or distributed applications are run at least for outward facing applications. Even though it is now nearly as easy to create rich client applications that run inside of the browser, the Web paradigm is still way, way more prominent than any rich client distributed scenarios. Smart Client applications continue to be a hard sell when it comes to public content. With the coming of WPF and the XAML markup language, Microsoft surely is hoping to have a compelling platform to build rich client applications that can directly run in the browser just like Web applications, but taking advantage of the super rich presentation layer that WPF provides. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;There&amp;#8217;s no doubt that WPF has huge potential to provide this rich and powerful platform, but it&amp;#8217;s by no means a foregone conclusion that it will take off for Web style distributed applications. Imagine that you could build rich applications that take advantage of all that Windows has to offer from rich rendering to advanced layout and databinding running native .NET code that you can actually debug. Wouldn&amp;#8217;t that be nice? But I wouldn&amp;#8217;t count it becoming a mainstream reality anytime soon, as much as I would love to see it happen.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;This smells very much of the Internet Explorer 4.0 model where IE at the time was a much more compelling platform to build Web applications for than most other browsers of the day. But even so it never took off as a dedicated platform with Web developers and developers in general sticking to a more generic approach that worked across platforms. We shall see &amp;#8211; I would actually love to be proven wrong by time &amp;lt;g&amp;gt;&amp;#8230;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;I think Microsoft realizes the continued importance of pure Web development and Atlas is a sign that this path will continue, even if it potentially has a negative impact on the adoption of WPF based Web interfaces. Atlas squarely steps in the path of WPF providing a model for building rich Web applications that can provide a more interactive user experience. Advances in the Web client platform have been in stagnation for quite some time, and hype or not, &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; is injecting a new vibrancy and energy into the Web application platform. Even in its simplest form &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; style Web applications can provide a better user experience and more interactive applications at the cost of a more complex client/server model. Atlas promises to ride that wave into new territory and possibilities for Web applications and hopefully provide an easier way for ASP.NET developers to get there.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Time will tell, but it&amp;#8217;s an interesting start.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=614931" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=614931</wfw:commentRss></entry><entry><title>ATLAS bits for RC posted </title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/26/614913.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:614913</id><created>2005-09-27T03:57:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Microsoft today posted the ATLAS bits that work properly with the September CTP or what has become the Release Canidate (RC) of VS.NET 2005. &lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;A href="http://lab.msdn.microsoft.com/vs2005/eula.aspx?id=63C6B54B-AF8F-453B-869B-0438DBBB781B"&gt;&lt;FONT face=Verdana size=2&gt;http://lab.msdn.microsoft.com/vs2005/eula.aspx?id=63C6B54B-AF8F-453B-869B-0438DBBB781B&lt;/FONT&gt;&lt;/A&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;I&amp;#8217;m so glad &amp;#8211; I&amp;#8217;ve been screwing around with my Beta 2 VPC that&amp;#8217;s seen better days and it&amp;#8217;s not been an optimal experience. I&amp;#8217;ve been working with Beta 2 for a while and it&amp;#8217;s been a frustrating experience at times, but the RC is a huge step up. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Say what you will VPC development sucks. Even with an external HD hooked it&amp;#8217;s damn slow compared to the main machine and if you end up switching back and forth between the VPC and host it&amp;#8217;s really bad. Add to that the perf difference between Beta 2 and the RC and you end up really not wanting to run the VPC session &amp;lt;g&amp;gt;. &lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;I was desperate enough to copy my beta 2 ATLAS project to the RC bits to see if it would run a few days ago, but that didn&amp;#8217;t work. None of the ATLAS callbacks were working with some odd low level framework errors. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Anyway, now with bits running on my main machine the going is much easier. Onwards&amp;#8230;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=614913" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=614913</wfw:commentRss></entry><entry><title>A Music Recording Relvation (sort of): I want a noise cancelling pedal &lt;g&gt;</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/24/614878.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:614878</id><created>2005-09-24T05:17:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;I was screwing around today with a riff that wouldn&amp;#8217;t go out of my head, so I decided that I need to record it. I&amp;#8217;m in &lt;?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /&gt;&lt;st1:place w:st="on"&gt;&lt;st1:PlaceName w:st="on"&gt;Hood&lt;/st1:PlaceName&gt; &lt;st1:PlaceType w:st="on"&gt;River&lt;/st1:PlaceType&gt;&lt;/st1:place&gt; and have only a little bit of my recording gear with me and it&amp;#8217;s not set up. So after about an hour of getting set up I was finally ready to lay down the damn track in Sonar with some canned ProAudio drums.&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;I&amp;#8217;ve been struggling with getting my digital recordings to sound decent, especially the heavy guitar tone. I have pretty good tone from the amp and the room, but I cannot for the life of me get good tone to record. Worse yet here, I&amp;#8217;m plugging into my Line &lt;st1:time w:st="on" Minute="00" Hour="6"&gt;6 am&lt;/st1:time&gt;p and using direct out from one of the amp models. It works&amp;#8230; but it sounds pretty flat.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;But here is the real kicker: I only have my shitty travel headphones with me here and predictably it sounds pretty weak between both the thin guitar recording and the headphones. The phones are optional noise canceling which I have off usually unless I am in fact on a plane or other noisy place.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;So I listened to this stuff and accidentally flipped the switch into noise canceling mode &amp;#8211; and MAN what a freaking difference. Whatever noise canceling does I want it on my guitar tone. It takes the wimpy winy sound and expands the shit out of it giving it the bottom end and bite that seems to be missing from the recording.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;So the 64 million dollar question from the sound ignorant person is &amp;#8211; what is it that noise canceling does and what is the equivalent guitar effect. &amp;lt;g&amp;gt; It&amp;#8217;s almost like it&amp;#8217;s Loudness on old stereos. It must be more than pure equalization as I can&amp;#8217;t equalize the tone to anything close to that. &lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Anybody have any ideas?&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=614878" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=614878</wfw:commentRss></entry><entry><title>Watch out for web.config Build Provider errors and Custom Controls on Toolbox</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/21/614867.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:614867</id><created>2005-09-21T21:51:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;I just spent 20 minutes trying to figure out why I was unable to drop a custom control onto a Web Page in ASP.NET 2.0. I&amp;#8217;ve been going back and forth between ASP.NET 2.0 beta installs and in one of my applications the same controls worked just fine, but in this app trying to drag the controls from the toolbox simply gave an error:&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Control cannot be created because Visual Studio cannot find the control&amp;#8217;s type in the control assembly&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/I&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/I&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;This error would lead you to believe that there&amp;#8217;s something wrong with your control&amp;#8217;s assembly or the control class itself. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Not so. This error apparently occurs whenever a control cannot be dropped and the reasons for this are many.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;In my case the problem was that my Web.Config was invalid and had an invalid build provider config setting:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: maroon; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;buildProviders&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: maroon; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;add&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;extension&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;.wwpd&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;type&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;System.Web.Compilation.PageBuildProvider&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;appliesto&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;Web&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: maroon; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;add&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;extension&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;.wcsx&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;type&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;System.Web.Compilation.PageBuildProvider&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;appliesto&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;Web&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: maroon; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;buildProviders&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue; FONT-FAMILY: 'Courier New'; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW; mso-no-proof: yes"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;The appliesto=&amp;#8221;Web&amp;#8221; is no longer legal in post beta 2 builds and this caused the control to no longer work. Once I removed the appliesto &amp;#8211; presto all is well.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;My application clearly pointed me at that error &amp;#8211; kudos for VS.NET to do that &amp;#8211; but it&amp;#8217;s not quite obvious while you&amp;#8217;re working on your form that a Web.config setting can affect your control dropping ability.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Hopefully this will help somebody out and save you 20 minutes (then again if you are searching for it &amp;#8211; it&amp;#8217;s probably easily been 20 minutes so far &amp;lt;g&amp;gt;)&amp;#8230;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=614867" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=614867</wfw:commentRss></entry><entry><title>Installed VS.NET 2005 Release Candidate</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/19/614795.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:614795</id><created>2005-09-19T06:22:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;I took a risk yesterday and went ahead an installed the Release Candidate of Visual Studio .NET 2005 on my main machine after uninstalling Beta 2. I've been running on VPC with August CTP for a few weeks and even on VPC the performance and operation of VS.NET appeared to be much smoother than Beta 2. But it's VPC - I hate working in VPC other than testing. But I've been hesitant to blow away my Beta 2 install, since it's been stable and my past experiencing trying to uninstall VS and then reinstalling a new version haven't been the most successful resulting in machine re-installs most of the time.&amp;nbsp; &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Uninstalling and re-installing versions of Visual Studio in the past has been a major pain point, but I&amp;#8217;m happy to report that following the uninstall directions resulted in a good install first try&amp;#8230; Well, almost. My MSDN install didn&amp;#8217;t let me see any dev topics, so I had to run Repair on that install, but after that all was well.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;I haven&amp;#8217;t spent much time with it yet, but on first look this is a much improved install. Most noticeable is the much improved performance of the IDE, which no longer seems to hang up and be stuck &amp;#8216;thinking&amp;#8217; between clicks and keystrokes.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;A number of things that had me quite a bit worried in the IDE was performance of Compilation of largish Web sites especially but it looks like the performance of the site compilation is now much quicker and up to what you&amp;#8217;d expect (in fact faster than VS 2003). It also uses incremental compilation for the Web sites which wasn&amp;#8217;t the case before and was the main reason for the slowness in Beta 2 I suspect.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;I also noticed that debugging performance has gotten much better especially using the internal Web Server. Starting a project for the first time is much quicker and applications running seem to be much snappier as well.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;The other good news is that other than the changes that occurred in ScriptCallbacks in ASP.NET in August CTP (the ICallbackEventHandler interface changed to two methods instead of one), the 3 Web apps and the 5 or so WinForm utility apps running Beta 2 all updated without any problems that I can tell so far. It&amp;#8217;s going to take some retesting and checking before I can trust that assessment, but the code compiles and there are no errors in preliminary test runs.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;I&amp;#8217;m relieved to see the stability and performance improvements in VS.NET. Although I realize that Beta 2 was still a ways off from release there were A LOT of quirks in it and it was a bit scary to see so many loose ends that late in the game. The RC seems to be addressing most of these issues.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;/o:p&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;One thing that does seem to be broken is the Font configuration. A number of the font options don't seem to work right. I can't seem to get my string background set and some of the text options (like keywords) will not go bold properly (for presentation size). Setting fonts in VS.NET is a PITA anyway, but unless I'm missing some new options I cannot figure out how to get my main code view text to go bold...&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Still, I&amp;#8217;m stoked &amp;#8211; now if I could only deploy the RC bits&amp;#8230; grrr. I&amp;#8217;m tired of waiting&amp;#8230; &amp;lt;g&amp;gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=614795" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=614795</wfw:commentRss></entry><entry><title>IIS 6 Kernel Caching from an ISAPI Extension - eek!</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/15/603980.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:603980</id><created>2005-09-16T04:06:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Arrgh&amp;#8230; After talking with some of the IIS team folks yesterday here at PDC about Kernel Caching in IIS, I thought it&amp;#8217;d be nice to add this functionality to the &lt;A title="" href="http://www.west-wind.com/wconnect/"&gt;Web Connection&lt;/A&gt; ISAPI extension. Kernel Caching uses a special ISAPI &amp;#8216;function&amp;#8217; description HSE_REQ_VECTOR_SEND, which supports setting a few flags that are supposed to have IIS kick in cache the URL internally. What this does is basically cache a dynamic request similar to the way that a static file is cached in IIS. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;This is server caching, not to be confused with browser or proxy caching. This means IIS is caching the file internally and when another hit to the same URL occurs the URL is served from the cache and not refreshed so the ISAPI extension is not called again until the Cache entry times out.&amp;nbsp;You can set the duration of the cache via an Expires header that can be passed in optionally.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;The benefit of this of course is that it takes the caching load completely out of the hands of the ISAPI extension, which in the case of &lt;A title="" href="http://www.west-wind.com/wconnect/"&gt;Web Connection&lt;/A&gt; which is a fairly heavy weight COM server. It provides a performance improvement of an order of magnitude for pages that can truly be cached in this way. On my site this immediately brings a few things to mind, especially the various RSS feeds which are now cached application side.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Now, implementing this function is something I looked into a few months ago and gave up because of the horrible, horrible documentation on the Microsoft site. Yes, in hindsight I suppose it makes some sense, but even given that, without the help of a Microsoft dev today at PDC I probably never would have figured this out completely.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;First things first. Kernel caching is cool but there are number of rules that need to be applied.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-list: l0 level1 lfo1; tab-stops: list .5in"&gt;&amp;nbsp;&lt;/P&gt;&lt;/FONT&gt;&lt;/FONT&gt;
&lt;UL style="MARGIN-TOP: 0in" type=disc&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-list: l0 level1 lfo1; tab-stops: list .5in"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;Requests must be under 255k&lt;BR&gt;&lt;/B&gt;Actually the value for this is configurable, but there&amp;#8217;s a stock value for the result message size. Kernel caching doesn&amp;#8217;t kick in for larger files. The value is configurable in the registry (see KB article reference later).&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-list: l0 level1 lfo1; tab-stops: list .5in"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;Works only with IIS 6&lt;BR&gt;&lt;/B&gt;This feature only works with IIS 6.0 (and possibly IIS 5.1 on XP SP2 &amp;#8211; not sure though). Not a big deal except it&amp;#8217;s hard to test exact behavior in a non-IIS 6 environment like developing in XP.&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-list: l0 level1 lfo1; tab-stops: list .5in"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;Requests require Last-modified header&lt;BR&gt;&lt;/B&gt;In order for Kernel Caching to kick in a Last-modified and optionally an Expires header must be provided to IIS. These are used to manage the cache duration.&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-list: l0 level1 lfo1; tab-stops: list .5in"&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;&lt;STRONG&gt;( Requests cannot have a query string )&lt;BR&gt;&lt;/STRONG&gt;This is a pretty big limitation for dynamic applications, but any page that contains query strings cannot be cached. This means Kernel caching requires either that you create a vanity URL, or simply don&amp;#8217;t require a query string for the page. If a querystring is used there will still be browser caching (same user, same request might not hit the server) but not server side caching.&lt;BR&gt;&lt;EM&gt;(the above is according to a KB article that describes limitations. In my own testing it looks like IIS 6 is caching query string requests just fine)&lt;/EM&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;There are a boatload of more rules that a bit more obscure and not as likely to affect you, but you can find them in this KB Article here&lt;/FONT&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;A href="http://support.microsoft.com/?id=817445"&gt;http://support.microsoft.com/?id=817445&lt;/A&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;To use Kernel Caching you use the ISAPI ServerSupportFunction() callback method with the HSE_REQ_VECTOR_SEND option. This option requires that you set up a request structure that breaks out the header and the body of the request and sends it as a single string to the ServerSupport function.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;The following is a C++ function that takes an full HTTP response including HTTP headers as input splits them up, sets up the various structures required and then calls ServerSupportFunction for caching:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;/*&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;CacheOutput&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;Caches output for a full request string in the IIS Kernel Cache.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;Assumes you have already made sure that:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;Header is included in the request&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;includes Last-Modified and Expires headers&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;*/&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;BOOL CacheOutput(EXTENSION_CONTROL_BLOCK *pEcb,&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt; *lpOutput,DWORD cbSize)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;HSE_RESPONSE_VECTOR&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;vec;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;HSE_VECTOR_ELEMENT element;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;DWORD HeaderSize = 0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt; *strHeader;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;// *** find end of header&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt; *Content = strstr((&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;const&lt;/SPAN&gt;&lt;/B&gt; &lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt; *) lpOutput,&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"\r\n\r\n"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;*Content=0; &lt;SPAN style="COLOR: green"&gt;// null terminate&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//// *** if we have no header end just send it as part of request&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//// *** Otherwise split it out with &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;strHeader = &lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;new&lt;/SPAN&gt;&lt;/B&gt; &lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt;[ strlen(lpOutput)&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;+ 1]; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;strHeader[0] = 0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;strcpy(strHeader,lpOutput);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;strcat(strHeader,&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"\r\n\r\n"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Content = Content + 4; &lt;SPAN style="COLOR: green"&gt;// Skip over header breaks&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;HeaderSize = strlen( strHeader ) ; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;element.ElementType = HSE_VECTOR_ELEMENT_TYPE_MEMORY_BUFFER;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;element.cbOffset = 0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;element.cbSize = cbSize-HeaderSize;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;element.pvContext = Content;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;vec.pszHeaders = strHeader;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;vec.lpElementArray = &amp;amp;element;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;vec.nElementCount = 1;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;vec.pszStatus = &lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"200 OK"&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;vec.dwFlags = HSE_IO_FINAL_SEND | HSE_IO_CACHE_RESPONSE | HSE_IO_SEND_HEADERS;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;BOOL Result = pEcb-&amp;gt;ServerSupportFunction(pEcb,HSE_REQ_VECTOR_SEND,&amp;amp;vec,NULL,NULL);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;delete&lt;/SPAN&gt;&lt;/B&gt;(strHeader);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;return&lt;/SPAN&gt;&lt;/B&gt; TRUE;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;This function takes a full response string as input and it assumes the content is prefiltered and contains an embedded http header. Typical input looks like this:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;HTTP/1.1 200 OK&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;Content-type: text/html&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;P3P: CP="ALL CRA TAA OWW &lt;?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /&gt;&lt;st1:State w:st="on"&gt;&lt;st1:place w:st="on"&gt;IND&lt;/st1:place&gt;&lt;/st1:State&gt; PHY ONL"&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;Last-Modified: Fri, 16 Sep 2005 04:13:52 GMT&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;Expires: Fri, 16 Sep 2005 04:23:52 GMT&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;o:p&gt;&lt;FONT size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-FAMILY: 'Courier New'"&gt;&lt;FONT size=2&gt;&amp;#8230; more HTML&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;which is a typical response that &lt;A title="" href="http://www.west-wind.com/wconnect/"&gt;Web Connection&lt;/A&gt; might generate to force caching. In this case the cache would be 10 minutes. Notice the Last-Modifed and Expires header, which the &lt;A title="" href="http://www.west-wind.com/wconnect/"&gt;Web Connection&lt;/A&gt; ISAPI DLL uses as a trigger (in addition to an IIS 6 check) to fire the above method.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Note in the code above that you have to make sure to split the HTTP headers off the main content. Make sure that the Headers contain the two trailing CRLFs or else IIS will not interpret the headers and simply write them out as is. That threw me for a loop as I assumed IIS would accept the headers without the trailing CRLFs. Once I added them in the code started caching properly.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;My mainline ISAPI code then checks for a set of conditions (IIS version, Content Length and headers), which if verified cause the code to branch and call the CacheOutput method instead.&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;This is some internal stuff here, but it should give you an idea of what to check for:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;// *** If we use Caching - use Vector Send to send the whole file&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;//&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Works only IIS 6.0&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;B&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: blue; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;( gnServerMode &amp;gt; 11 &amp;amp;&amp;amp;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;ContentLength &amp;lt; 255000 &amp;amp;&amp;amp; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; TEXT-INDENT: 24pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;stristr(lpHeader,&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"last-modified:"&lt;/SPAN&gt;) &amp;amp;&amp;amp; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; TEXT-INDENT: 24pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;stristr(lpHeader,&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"expires:"&lt;/SPAN&gt;) )&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;DWORD Result = 0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;try&lt;/SPAN&gt;&lt;/B&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt; *OutputBinary = (&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt; *) &lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;new&lt;/SPAN&gt;&lt;/B&gt; &lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&lt;/B&gt;[&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;ContentLength + 4 ];&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;ReadFromFile(pParam-&amp;gt;szOutputFileName,OutputBinary,&amp;amp;ContentLength);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;OutputBinary[ContentLength] = 0; &lt;SPAN style="COLOR: green"&gt;// null terminate&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Result = CacheOutput(ecb,OutputBinary,ContentLength);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;delete&lt;/SPAN&gt;&lt;/B&gt;(OutputBinary);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;catch&lt;/SPAN&gt;&lt;/B&gt;(...)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{ &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;StandardPage(&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"An error occurred"&lt;/SPAN&gt;,&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"The application failed to write Cached Output to the Cache Store."&lt;/SPAN&gt;,&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 6"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;ecb,&lt;SPAN style="BACKGROUND: silver; mso-highlight: silver"&gt;"CacheOutputFailure"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Result = FALSE;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;&lt;SPAN style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: blue"&gt;return&lt;/SPAN&gt;&lt;/B&gt; Result;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: Consolas; mso-fareast-font-family: PMingLiU; mso-fareast-language: ZH-TW"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;This is very cool and I have a number of places where this functionality can be applied right away, so I&amp;#8217;m stoked. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Hopefully this will help make life a little easier for anybody else who needs to use HSE_REQ_VECTOR_SEND and Kernel Caching&amp;#8230; &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Note that for the moment I didn't mess around with Cache invalidation API which is also available.&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=603980" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=603980</wfw:commentRss></entry><entry><title>My ASP.NET Script Callbacks Article Part 1 went live on ASP Today today</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/15/603981.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:603981</id><created>2005-09-15T06:23:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;My ASP.NET 2.0 Script Callbacks article Part 1 went live today on the ASP TODAY site today. This two part article series is a lengthy look at the first &lt;?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /&gt;&lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; like functionality Microsoft is shipping in ASP.NET 2.0 and what you can do with it. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;The article covers the good and the bad of this technology, which is getting overshadowed by what Atlas promises much further down the road. However, Script Callbacks are built into ASP.NET 2.0 in the box and are going to be available as soon as .NET 2.0 ships.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Check it out at:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;My ASP.NET 2.0 Script Callbacks article Part 1 went live today on the ASP TODAY site today. This two part article series is a lengthy look at the first &lt;st1:City w:st="on"&gt;&lt;st1:place w:st="on"&gt;AJAX&lt;/st1:place&gt;&lt;/st1:City&gt; like functionality Microsoft is shipping in ASP.NET 2.0 and what you can do with it. While a stop gap technology between what&amp;#8217;s available now and what&amp;#8217;s coming &amp;#8211; especially in light of the power of what Atlas promises in the future &amp;#8211; it&amp;#8217;s technology that&amp;#8217;s going to be in the box and usable much sooner.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Check it out at:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;A href="http://www.asptoday.com/Content.aspx?id=2381"&gt;http://www.asptoday.com/Content.aspx?id=2381&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;The ASP Today site is a registration site so you need to register and I believe back content is only for subscribers.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;The ASP Today site is a registration site so you need to register and I believe back content is only for subscribers.&lt;/FONT&gt;&lt;/P&gt;&lt;/P&gt;&lt;img src="http://thedotnet.com/aggbug.aspx?PostID=603981" width="1" height="1"&gt;</content><slash:comments>0</slash:comments><wfw:commentRss>http://thedotnet.com/blogs/rick_strahl/commentrss.aspx?PostID=603981</wfw:commentRss></entry><entry><title>Understanding Page Inheritance in ASP.NET 2.0</title><link rel="alternate" type="text/html" href="http://thedotnet.com/blogs/rick_strahl/archive/2005/09/12/595724.aspx" /><id>664cd7bf-d3e2-49b0-a47d-b85ea0b2bdd0:595724</id><created>2005-09-12T08:17:00Z</created><content type="text/html" mode="escaped">&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;In ASP.NET 1.x the primary code model is based on CodeBehind, which uses inheritance and code generation to manage the code that you as the developer work with. In V1 you create a base class into which the VS.NET Editor generates control definitions from the HTML markup – each control gets an instance field on the form and any explicit event hookups are stuck into the InitalizeComponent section of the page. The ASP.NET engine then generates a class from the HTML markup and inherit from your CodeBehind form, in effect providing the functionality you implemented in that class in addition to the generated code.&lt;/FONT&gt;&lt;/P&gt;
&lt;H3&gt;&lt;FONT face=Verdana color=#000080 size=2&gt;Some problems with the 1.1 model&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;The concept’s pretty straight forward, but in VS.NET 2003 there are lots of problems with this approach that had to do with the code generation into the CodeBehind class. In many cases control declarations would not make it, or event declarations would get lost. Who’s ever lost their datagrid events after saving a page or copying a couple of controls around on it? Worse, if you removed a control from a page VS.NET wouldn’t clean up after itself and leave the declaration and event hook up code in the CodeBehind class. It’s even worse if you were using a plain text editor to manage this on your own, as you’d have to remember to match control definitions in the markup to control definitions and event hookups in the class, so you always have to maintain code in two places.&lt;/FONT&gt;&lt;/P&gt;
&lt;H3&gt;&lt;FONT face=Verdana color=#000080 size=2&gt;How ASP.NET 2.0 addresses these issues&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;In ASP.NET 2.0, the CodeBeside model addresses this issue with Partial Classes. The core model is still the same and based on inheritance, but the rather than using a single class definition ASP.NET 2.0 breaks up the class into two partial classes that get combined at compile time. There’s the class that you write your code into – Page_Load() and any event implementations as well as any field definitions. And then there’s a generated class that contains all the Control definitions and event hookups. When the page is compiled both partial classes are combined and that class is then used as the base that is inherited by the Page parser generated class.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;The advantage of this approach is that there’s only one place that code generation occurs and it’s at page compile time. So even if you use a plain text editor to create your CodeBeside page it will automatically pick up your control definitions. No longer does VS.NET have to parse the document at design time (well it still does to provide Intellisense support) to create control definitions to inject into your source document. This is of course much more reliable and consistent and makes for much cleaner code. You only see the code you actually wrote yourself.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;Another advantage of the new page model is the fact that individual pages can (but don’t have to) compile into individual classes. ASP.NET 2.0 can compile pages individually or at the directory level. When you run ASP.NET in debug mode it uses single page compilation. Single page compilation is an awesome feature for debugging pages inside of VS.NET 2005. Because pages can individually compile when they are run you can now execute a page, make a change and immediately re-run the page without explicitly recompiling your project. This is much faster than the 1.1 change and compile steps you had to go through especially on larger projects. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;This works even if you are running in Debug mode; so you can step through code, find a problem, fix it in the editor and simply re-run the page. This is similar to the way single source debugging worked in ASP.NET 1.x but it now can also work with the more sophisticated and more realistic CodeBeside approach. As you might expect this is a huge timesaver, especially for large projects as you’re saving a long compile step, although the page recompilation is not super fast at least in Beta 2.&lt;/FONT&gt;&lt;/P&gt;
&lt;H3&gt;&lt;FONT face=Verdana color=#000080 size=2&gt;How it works&lt;/FONT&gt;&lt;/H3&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;ASP.NET 2.0 makes use of partial classes to provide this improved stability in the page model. The core model hasn’t change all that much from ASP.NET 1.1 as the combined classes are still very similar to the single codebehind page used in 1.1. You still have page inheritance where the ASPX page inherits from your partial class and the generated control definitions. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;At the CodeBeside level there are two partial classes: There’s the class that you write your code into – Page_Load() and any event methods as well as any field and property definitions and events that you want to define. This page is the ‘master’ partial class as it provides the inheritance structure where you can tell it what to inherit from. Typically it looks like this:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;namespace&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN&gt; Westwind.WebStore&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;public&lt;/SPAN&gt; &lt;SPAN&gt;partial&lt;/SPAN&gt; &lt;SPAN&gt;class&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;UploadItemPicture&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt; : System.Web.UI.&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;Page&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;B&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;protected&lt;/SPAN&gt; &lt;SPAN&gt;void&lt;/SPAN&gt; Page_Load(&lt;SPAN&gt;object&lt;/SPAN&gt; sender, &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;EventArgs&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt; e)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;… implementation here&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;protected&lt;/SPAN&gt; &lt;SPAN&gt;void&lt;/SPAN&gt; btnGo_Click(&lt;SPAN&gt;object&lt;/SPAN&gt; sender, &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;EventArgs&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt; e)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;B&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;… implementation here&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;B&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;Note that a partial class does not contain control definitions or InitializeComponent that usually hooks up the events. ASP.NET generates the surrogate partial class at compile time that represents the ASPX page code ASP.NET generates another partial class that contains all the control definitions, the event delegate hookups and setting of Page settings (like EnableSessionState, Trace etc.).&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;Both of these partial classes combine to make up the base class that the ASPX page inherits.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;This base page is inherited by the class that the ASP.NET page parser creates. The Page parser runs through all of the ASPX script code and creates a class from it that is made up of literal HTML content, expressions that are written straight out into the HtmlTextWriter object, and the Control tree that is parsed and then rendered. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;You can see this to a large degree if you throw the generated, compiled assembly into &lt;/FONT&gt;&lt;A href="http://www.aisto.com/roeder/dotnet/"&gt;&lt;FONT face=Verdana size=2&gt;.NET Reflector&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;. In case you don’t know about Reflector, run and don’t walk to get it – it’s an awesome tool to figure out how code works, be it your own, Microsoft’s or cough, cough any third parties that isn’t obfuscating their code. &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;BR&gt;&lt;FONT face=Verdana size=2&gt;ASP.NET generates assemblies from your classes using the ASP.NET compiler (ASPNET_COMPILER.EXE). You can pre-compile your project and look at the generated assemblies. For more info &lt;/FONT&gt;&lt;A href="http://west-wind.com/weblog/posts/2128.aspx"&gt;&lt;FONT face=Verdana size=2&gt;click here&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;. What you’ll find is something that looks like the Figure below which shows a composite assembly created from the precompiler with the following command line:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;B&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;"&amp;lt;frameworkPath&amp;gt;\aspnet_compiler.exe" -f -v "/wwstore" "d:\temp\deploy\wwstore"&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;I used a virtual IIS path (-v /wwstore) and compiled it into a fixed directory that is to overwritten (-f). This option create one assembly per directory of the Web application which combines all of the pages of the directory into one assembly all starting APP_WEB as the name prefix. The assemblies are randomly named, so finding the right one is not easy if you have more than one directory – usually you can guess by looking at the file sizes.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;Once you find the right assembly in Reflector it might look something like the figure below. In my case I’ll look at the UploadItemPicture page in the Web. Notice the two classes related to this in the ASP namespace and the Westwind.WebStore namespace:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;/o:p&gt;&lt;A href="http://west-wind.com/weblog/images/11/o_PageInheritance.png"&gt;http://west-wind.com/weblog/images/11/o_PageInheritance.png&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;The class on the bottom (UploadItemPicture) is my user class, which is the merged version of my partial class, plus the generated page control code and event hookup code. If you look at the properties and methods of this class you will find all the control definitions, which although they weren’t defined in your source code are now there. All of that comes from the generated partial class. The combined class looks pretty similar to an ASP.NET 1.x single CodeBehind class…&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;If you look closely at the figure above you can see that admin_uploaditempicture_aspx inherits from my UploadItemPicture class. The inherited class contains the actual page construction logic for instantiating each of the controls (__Build&amp;lt;ControlName&amp;gt;) and then renders the page using __BuildControlTree(). BuildControlTree is the top level routine that fires of the page rendering process. It renders the form literals, and then renders each of the controls inside of the page. It does this using the containership hierarchy so in this case there’s RenderForm1 which in turn renders each of the child controls. Depending on where controls appear in your page this may look differently. In my example above all other controls are inside of the Form tag, so the other controls are rendered as part of internal code of the Form object.&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;Each control (except the form tag which requires special handling) is rendered using RenderControl() for each of the control in the Controls Collection and each control manages its own rendering process.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT face=Verdana size=2&gt;BTW, if you quickly want to see the generated page source for the Partial class that has the above definitions in it – you can put an error into your script page in an expression. For example:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;b&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt;itemimages/&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&amp;lt;%&lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt; &lt;SPAN&gt;this&lt;/SPAN&gt;.ImageFileName_INVALID &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;%&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;br&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;On the resulting error page, click on the Show Complete Compilation Source and you should see the code displayed. You’ll want to trigger an error in the ASPX page to make this work, not in the CodeBeside code, because that shows you just the compilation code of your code behind partial class. It’s too bad we can’t see the combined class or at least both classes that make up the composite.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;H3&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT color=#000080&gt;&lt;FONT face=Verdana&gt;What to watch out for&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/H3&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;So far this all sounds really nice – ASP.NET 2.0 provides a solution to the nasty control mismatch problems that so often would creep up in V1 without really giving up any features. Well, mostly, but there are&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;a few issues you need to be careful of.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Most importantly you have to realize that part of your class is dynamically generated at compile time. What this means is that some things are not necessarily available to your code. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Let’s presume for a second I wanted to subclass an existing page and use it for a custom class like this:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;public&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN&gt; &lt;SPAN&gt;partial&lt;/SPAN&gt; &lt;SPAN&gt;class&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;UploadItemPictureEx&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt; : Westwind.WebStore.UploadItemPicture&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;protected&lt;/SPAN&gt; &lt;SPAN&gt;void&lt;/SPAN&gt; Page_Load(&lt;SPAN&gt;object&lt;/SPAN&gt; sender, &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;EventArgs&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN&gt; e)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;First off you’ll notice that VS.NET doesn’t show UploadItemPicture as an identified class (it’s black – it should be Teal colored text for a type name).&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;If you try to run this page it fails too. ASP.NET complains that it can’t find Westwind.WebStore.UploadItemPicture. This even though it exists in the same assembly! You can’t reference other Page classes in your code like this. This is true whether the code is in the same assembly or not. If the UploadItemPicture.aspx page were in a different directory it would end up in a completely different assembly and not visible at all to the current assembly because it doesn’t receive a reference to any of the other directories.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;This is a pretty major change in the way ASP.NET works. There’s a workaround for this, but it’s not pretty:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Create a base class for your page and make it inherit from Page&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt; 
&lt;LI class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Store this Page either in APP_CODE or in a separate assembly so it’s visible to your pages&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt; 
&lt;LI class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Implement your Public interface on this base Page&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt; 
&lt;LI class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Then create your Page and make it inherit from this base Page&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt; 
&lt;LI class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Now when you need to cast, cast to the base type&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;Yes, this is pretty ugly, but it works and it’s not too bad of a workaround once you know what to do. I doesn’t change the way you work much but it requires one additional class and remembering to expose the base methods and properties you want to access at the base&amp;nbsp;class level. You&amp;nbsp;still implement all your code at the UserControl level – the base class is merely there to give you the strongly typed base interface that you can use for Intellisense and getting the proper typecasting to access the interface without Reflection.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;H3&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT color=#000080&gt;&lt;FONT face=Verdana&gt;User Controls&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/H3&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&lt;FONT size=2&gt;&lt;FONT face=Verdana&gt;You have similar issues with controls, but the rules are a little more lenient b