Reputation: 1644
<%@ OutputCache Duration="10" VaryByParam="Button1" %>
I type the above code to vary text of Button but it does not vary the value .
Upvotes: 1
Views: 788
Reputation: 26436
VaryByParam
refers to query string parameters. Not the value of buttons or other controls.
For example:
http://www.example.com/mypage.aspx?id=10
http://www.example.com/mypage.aspx?id=20
Would be cached separately if you set:
<%@ OutputCache Duration="10" VaryByParam="id" %>
Upvotes: 6