Last post Jun 27, 2008 05:46 AM by einarq
May 19, 2008 05:49 PM|kenpachi|LINK
I was playing around with caching today and I noticed that if you use a Response.Write statement from the code-behind of a user-control that has output caching enabled it will not cache the Response.Write output. On the other hand if I store a value into
a public variable in a user-control and then in the markup use <% Response.Write(var-name); %> it caches it. What is the difference?
Jun 27, 2008 05:46 AM|einarq|LINK
I believe that only the result of the Render method is cached.
The markup is also returned from the Render method, any Response.Write calls made in the code-behind (other than in the Render method) will not be a part of the Render result.