Usage:
<%
Option expedition
Response.buffer = TRUE
Numcode
Function Numcode ()
Response.expires = -1
Response.addheader "Pragma", "NO-CACHE"
Response.addheader "Cache-Ctrol", "NO-CACHE"
Dim Znum, I, J
Dim ADOS, ADOS1
Randomize Timer
Znum = CINT (8999 * RND 1000)
Session ("getcode" = znum
DIM ZIMG (4), NSTR
NSTR = CSTR (Znum)
For i = 0 TO 3
ZIMG (i) = CINT (MID (NSTR, I 1, 1))
NEXT
DIM POS
SET ADOS = Server.createObject ("AdoDb.Stream")
ADOS.MODE = 3
ADOS.TYPE = 1
ADOS.OPEN
SET ADOS1 = Server.createObject ("AdoDb.Stream")
ADOS1.MODE = 3
ADOS1.TYPE = 1
ADOS1.OPEN
ADOS.LOADFROMFILE (Server.Mappath ("Body.fix")))
ADOS1.WRITE ADOS.READ (1280)
For i = 0 TO 3
Ados.position = (9-ZIMG (i)) * 320
ADOS1.PSITION = i * 320
ADOS1.WRITE ADOS.READ (320)
NEXT
ADOS.LOADFROMFILE (Server.Mappath ("Head.fix"))
POS = lenb (adoS.read ())
ADOS.PSITION = POS
For i = 0 to 9 Step 1
For j = 0 to 3
ADOS1.PSITION = i * 32 j * 320
ADOS.PSITION = POS 30 * J i * 120
ADOS.WRITE ADOS1.READ (30)
NEXT
NEXT
Response.contentType = "image / bmp"
ADOS.PSITION = 0
Response.binarywrite ads.read ()
ADOS.CLOSE: SET ADOS = Nothing
ADOS1.CLOSE: SET ADOS1 = Nothing
END FUNCTION
'Asp code created by blueidea.com Web Team V37 2003-7-25
%>