<%
Class Imgwhinfo ' Get a picture of the width and height of classes, support Jpg,gif,png,bmp
Dim ASO
Private Sub Class_Initialize
Set aso=server.createobject ("ADODB. Stream ")
ASO. Mode=3
ASO. Type=1
ASO. Open
End Sub
Private Sub Class_Terminate
Err.Clear
Set aso=nothing
End Sub
Private Function bin2str (Bin)
Dim I, Str
For I=1 to LenB (Bin)
CLOW=MIDB (bin,i,1)
If ASCB (Clow) <128 Then
str = str & CHR (ASCB (Clow))
Else
I=i+1
If I <= LenB (Bin) Then str = str & CHR (ASCW (MidB (bin,i,1) &clow))
End If
Next
Bin2str = Str
End Function
Private Function num2str (num,base,lens)
Dim Ret
Ret = ""
while (Num>=base)
ret = (Num Mod Base) & RET
Num = (num-num Mod Base)/base
Wend
Num2str = Right (String (Lens, "0") & Num & Ret,lens)
End Function
Private Function Str2Num (str,base)
Dim Ret,i
Ret = 0
For I=1 to Len (STR)
RET = ret *base + Cint (Mid (str,i,1))
Next
Str2num=ret
End Function
Private Function Binval (Bin)
Dim Ret,i
Ret = 0
For I = LenB (Bin) to 1 Step-1
RET = ret *256 + AscB (MidB (bin,i,1))
Next
Binval=ret
End Function
Private Function BinVal2 (Bin)
Dim Ret,i
Ret = 0