IT SOLUTIONS
Your full service technology partner! 
-Collapse +Expand
ASP Classic
Search ASP Classic Group:

Advanced
-Collapse +Expand ASP Classic Store

Prestwood eMagazine

June Edition
Subscribe now! It's Free!
Enter your email:

   ► KBWebsite Scri...ASP ClassicLanguage Det...   Print This     
  From the January 2016 Issue of Prestwood eMag
 
ASP Classic Language Details:
ASP Application.Lock Method
 
Posted 17 years ago on 11/14/2006 and updated 1/29/2009
Take Away:

Call Application.Lock to freeze ASP code while you set IIS application variables the Application.Unlock to unfreeze. No actions take place on the server while locked. 

Application.Lock

Application(YourAppVar) = AValue
Application.Unlock
 
 A flashcard from our ASP Classic Flashcards Library
 A tip from our ASP Classic Tips Page

KB100409

Example

Use the Application.Lock method to lock the application object so that no actions take place on the server. For example, when you change a recordset that is kept in memory. Use Application.Unlock to unlock the application object and allow the continuation of ASP code.

Application.Lock

Application(AppVarDateTime) = Now
Application.Unlock
While the Application object is locked, no ASP code is executed and no ASP pages are served to visitors. If you do not unlock the application it will remain locked!

Comments

1 Comments.
Share a thought or comment...
Comment 1 of 1

"While the Application object is locked, no ASP code is executed ..." -- seriously?!  So how would "Application.Unlock" ever get executed?

---
Seriously
Posted 9 years ago
 
Write a Comment...
...
Sign in...

If you are a member, Sign In. Or, you can Create a Free account now.


Anonymous Post (text-only, no HTML):

Enter your name and security key.

Your Name:
Security key = P174A1
Enter key:
Tip Contributed By Mike Prestwood:

Mike Prestwood is a drummer, an author, and creator of the PrestwoodBoards online community. He is the President & CEO of Prestwood IT Solutions. Prestwood IT provides Coding, Website, and Computer Tech services. Mike has authored 6 computer books and over 1,200 articles. As a drummer, he maintains play-drums.com and has authored 3 drum books. If you have a project you wish to discuss with Mike, you can send him a private message through his PrestwoodBoards home page or call him 9AM to 4PM PST at 916-726-5675 x205.

Visit Profile

 KB Article #100409 Counter
16465
Since 4/2/2008
Sales Website: www.prestwood.com Or visit our legacy sales site: 
legacy.prestwood.com


©1995-2023 Prestwood IT Solutions.   [Security & Privacy]