Tribute
Home Testimonials Contents Tribute

 

                                               

 

 

 

 

Welcome to Twinless Twins

<% 'Option Explicit 'Dimension variables Dim fsObject 'File System Object 'Create a File System Object variable set fsObject = Server.CreateObject("Scripting.FileSystemObject") 'Initialise a File Object with the path and name of text file to open set fileObject = fsObject.GetFile(Server.MapPath("hit_test.txt")) Dim fileObject 'File Object Dim tsO 'Text Stream Object 'Open the visitor counter text file set tsO = fileObject.OpenAsTextStream 'Dim lngVisitorNumber           'Holds the visitor number Dim intWriteDigitLoopCount 'Loop counter to display the graphical hit count 'Read in the visitor number from the visitor counter file lngVisitorNumber = CLng(tsO.ReadAll) 'Increment the visitor counter number by 1 lngVisitorNumber = lngVisitorNumber + 1 'Create a new visitor counter text file over writing the previous one set tsO = fsObject.CreateTextFile(Server.MapPath("hit_test.txt")) 'Write the new visitor number to the text file tsO.Write CStr(lngVisitorNumber) 'Reset server objects Set fsObject = Nothing Set tsO = Nothing Set fileObject = Nothing 'Loop to display graphical digits For intWriteDigitLoopCount = 1 to Len(lngVisitorNumber) 'Display the graphical hit count Response.Write("") Next %>