Microsoft Knowledge Base Article
This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved.
Terms
of Use |
Trademarks
Article ID: 171365 - Last Review: October 24, 2003 - Revision: 2.0
FIX: VBS 2.0 String Formatting Functions Leak Memory
This article was previously published under Q171365
Applications that use the Visual Basic Scripting (VBS) version 2.0 string
formatting functions, such as FormatNumber and FormatCurrency, may
experience memory leaks. The increased resource usage caused by these
memory leaks is particularly important when VBS is used in the Active
Server Pages (ASP) environment due to the high volume nature of Web
servers.
There are known code defects in the following VBS 2.0 functions, which
promote resource leaks:
- Filter
- FormatCurrency
- FormatDateTime
- FormatNumber
- FormatPercent
- Replace
In VBS version 2.0, there are two workarounds for this problem:
- Avoid using these functions, especially in high-volume environments such as
ASP.
- Create your own string formatting functions to replace those provided by
VBS. In the case of ASP, this would best be done by creating a server-side
component (COM object) that exposes the appropriate formatting methods.
Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article. This bug was corrected in Microsoft Internet Explorer 5.
APPLIES TO
- Microsoft Visual Basic, Scripting Edition 2.0
- Microsoft Active Server Pages 4.0
| kbbug kbfix kbie500fix KB171365 |
Retired KB Content DisclaimerThis article was written about products for which Microsoft no longer offers support. Therefore, this article is offered "as is" and will no longer be updated.
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