Home | Advertising Info5 USERS CURRENTLY ONLINE   
   Site Search Contact Us Friday, March 14, 2025  
 
 


 
ASPProtect
User Management Application with web based screens that allow you to manage users.
www.ASPProtect.com
 
ASPBanner
Banner Rotation system. Advertisers can monitor online statistical reports via their web browsers.
www.ASPBanner.com
 
ASP Photo Gallery
Upload an unlimited amount of albums. Set up categories.Image resizing thumbnail creation.
www.ASPPhotoGallery.com
 
ASPClassifieds
Classifieds system. Set up categories. Users can register themselves. Supports picture uploads.
www.ASPClassifieds.com



DISCUSSION ARCHIVES
 



We didn't realize
the site was so popular.

Other Stuff
 

 
 
Active Server Pages what is asp programming how to sample asp example code scripts software asp forum mail sessions applications global.asa CJWSoft ASPProtect ASPBanner ASPClassifieds



(Advanced)  (Components)  (Database)  (General)  (Vbscript)




ASPProtect

 
Subject: Revised question
From: Kevin
Date: 3/2/2000 10:44:07 AM
IP: 156.153.255.178



 

Ok so I found a sample on this web site of how to schedule an asp script to execute, so now I have just one question, about 2/3s the way down it says "Here you would put any code you need to run"
ok that makes sense, but for some reason Im not coming up with the right syntax. So what code would I put in there to run my script?

Your help would be greatly appreciated

Here is the sample I found, I found it at
http://www.powerasp.com/content/hintstips/schedule-global.asp



<SCRIPT LANGUAGE=VBScript RUNAT=Server>

Sub Application_OnStart
Application("SessionCount") = 0
End Sub

Sub Session_OnStart

Application.Lock
Application("SessionCount") = Application("SessionCount") + 1
Application.Unlock

If Application("SessionCount") > 15 Then

Application.Lock
Application("SessionCount") = 0
Application.Unlock

Set ObjMyFile = CreateObject("Scripting.FileSystemObject")
Set OpenMyFile = ObjMyFile.OpenTextFile(Server.MapPath("last-update.txt"))
MyFileValue = OpenMyFile.ReadLine
OpenMyFile.Close

If DateDiff("h",MyFileValue,NOW) > 6 Then

Here you would put any code you need to run
do not surround the code with <% %> tags
For example you might run a database query that checks for expired accounts

Set WriteMyFile = ObjMyFile.CreateTextFile(Server.MapPath("last-update.txt"))
WriteMyFile.WriteLine(NOW)
WriteMyFile.Close

End if
End If

End Sub

</SCRIPT>

Follow Up - Re: Revised question - Chris Mangano 3/13/2000 7:07:24 PM


 

   Active Server Pages Rule The World
Contact Us  
All artwork, design & content contained in this site are Copyright © 1998 - 2025 PowerASP.com and Christopher J. Williams
Banner ads ,other site logos, etc are copyright of their respective companies.
STATS Unless otherwise noted - All Rights Reserved.

PowerASP active server pages asp.net microsoft .net framework sdk learn asp what is asp tutorial learn asp.net CJWSoft ASPProtect ASPBanner ASPClassifieds www.aspclassifieds.com, www.powerasp.com,www.cjwsoft.com,www.aspphotogallery.com,www.codewanker.com,www.aspprotect.com,www.aspbanner.com