Microsoft Knowledge Base Article
This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved.
Terms
of Use |
Trademarks
Article ID: 917411 - Last Review: December 3, 2007 - Revision: 1.6
The System.Web.Caching.Cache object is not intended for use outside ASP.NET in the .NET Framework 1.1 and in the .NET Framework 1.0
The
System.Web.Caching.Cache object in the Microsoft .NET Framework 1.1 and in the Microsoft .NET Framework 1.0 is not intended for use outside Microsoft ASP.NET. The
Cache object was designed and tested for use by ASP.NET to provide ASP.NET caching. If you try to use
Cache objects in other types of applications, such as console applications or Windows Forms applications, the
Cache objects may not work correctly.
Note The specific problem that is described in the "More Information" section does not occur in the Microsoft .NET Framework 2.0. Therefore, you can use the
Cache object outside ASP.NET in the .NET Framework 2.0. However, we recommend that you consider using the Caching Application Block because it offers you more options for customization to meet application requirements.
You cannot create a
System.Web.Caching.Cache object on an operating system that does not have ASP.NET installed.
Cache object cleanup is provided by the ASP.NET infrastructure, and expired or unused
Cache objects cannot be automatically removed if the application is not an ASP.NET application. Therefore, if
Cache objects are used outside ASP.NET, the system memory that is reserved for the
Cache objects is not released. You cannot manually invoke the internal ASP.NET methods to clean up the cache because the methods are marked as internal and intended for internal use.
The .NET Framework 1.1 does not contain a general-purpose object to provide cache support outside ASP.NET. However, the Microsoft Patterns and Practices series of application blocks includes a Caching Application Block that is designed to be reused in many different types of applications.
For more information about the Caching Application Block, visit the following Microsoft Developer Network (MSDN) Web site:
For more information about the
System.Web.Caching.Cache object, visit the following MSDN Web site:
APPLIES TO
- Microsoft .NET Framework 1.0
- Microsoft .NET Framework 1.0 Service Pack 1
- Microsoft .NET Framework 1.0 Service Pack 2
- Microsoft .NET Framework 1.0 Service Pack 3
- Microsoft .NET Framework 1.1
- Microsoft .NET Framework 1.1 Service Pack 1
| kbcaching kbcache kbtshoot kbinfo kbprb KB917411 |
Community Feedback System
Very often, it takes hours to solve a problem. Very often, you've looked high
and low, and have tried a lot of solutions. When you finally found it, chances
are, it was because someone else helped you. Here's your chance to give back.
Use our community feedback tool to let others know what worked for you and what
didn't.
Please also understand that the community feedback system is not warranted to be
correct, it's simply a system that we've built to let people try and help each
other. If something in a feedback response doesn't make sense to you, or you're
not comfortable making changes that the feedback talks about (like registry
edits), please consult a professional.
Thank you for using kbAlertz.com Feedback System.
-- Scott Cate
Be the first to leave feedback, to help others about this knowledge base
article.
(Optional) Name
(Optional)
Public URL Or Email
Comments
No
HTML -- Text Only Please