% function counts(counterfile) dim objfso,objts application.lock set objfso = server.createobject("scripting.filesystemobject") set objts = objfso.opentextfile(server.mappath("\study\counter.txt"),1,true) if not objts.atendofstream then counts = clng(objts.readline) end if counts = counts + 1 objts.close set objts = objfso.opentextfile(server.mappath("\wyu\counter.txt"),2,true) objts.writeline (counts) objts.close application.unlock end function