Hi Friends
Explain the use of duration attribute of @OutputCache page directive.
@OutputCache page directive
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Satyapriya NayakRank #47 · 31.5K reputationPosted Mar 3, 2012, 6:06 PM EST
The Duration parameter specifies how long, in seconds, the HTML output of the Web page should be held in the cache. When the duration expires, the cache becomes invalid and, with the next visit, the cached content is flushed, the ASP.NET Web page's HTML dynamically generated, and the cache repopulated with this HTML.
Thanks
Jignesh TrivediRank #16 · 50.3K reputationPosted Mar 4, 2012, 5:44 PM EST
@outputcaching used cache asp.net page or user control.
Duration is time in second that the page or usercontrol is cached. rhis attribute is required. it gives complation error if it not passed.
hope this help.