Need help using varybycontrol
I am learning ASP.Net and I am trying to use OutputCache - varybycontrol based on tutorial like this:
<%@ OutputCache duration="15" varybyparam= "none" varybycontrol="txtName" %>
Somehow txtName which is my textbox doesn't get cache, without the varybycontrol it works fine for caching all controls in the form. Can someone please advice, thanks.开发者_如何学JAVA
If you're using Master/content pages then VaryByControl won't work.
See explanation here: http://connect.microsoft.com/VisualStudio/feedback/details/465461/outputcache-varybycontrol-cannot-be-used-in-content-pages
精彩评论