How is it possible to create various cached versions of a user control based on a field within the control. So for example I have a user control that has the following declaration:
int someInt = 0;
Let's say this variable could be set to any value between 1 and 10. If I want a separate cached user control for each value of the variable - how do I achieve this?
What you need is VaryByControl. See
Vary by control properties using PartialCaching in ASP.NET
for details.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.