Sto usando l'upload di Baol ma nont rovo la funzione/comando che mi restituisce/controlla le dimensioni di un immaggini

Es. 200px*200px



Ho trovato questo nel codice

codice:
	Public Function GetImageSize(FileName,byRef width, ByRef height,byRef info)
	Dim Bin,ar
		Stream.Type = 1
		Stream.Open
		Stream.LoadFromFile FileName
		Bin = Stream.Read
		pGetImageSize Bin,Mid(FileName,InStrRev(FileName,".")+1),ar
		height = ar(0)
		Width = ar(1)
		Info = ar(2)
		Stream.Close
	end function




Private Function pGetImageSize(byRef RequestBin,ContentType,ByRef arResult)
	Dim h,w,Tmp,Size,segment,Pos,SOfLenght,Info,hH,Marker,arSOF,FileSize
		h=-1:w=-1
			Select Case lcase(ContentType)
				case "image/pjpeg","image/jpeg","jpg","jpeg":
					arSOF =	Array("baseline DCT Huffman","extended sequential DCT Huffman",_
							"progressive DCT Huffman","spatial lossless Huffman",_
							"SOF4","differential sequential DCT Huffman",_
							"differential progressive DCT Huffman","differential spatial Huffman",_
							"SOF8","extended sequential DCT arithmetic",_
							"progressive DCT arithmetic","spatial lossless arithmetic",_
							"SOF12","differential sequential DCT arithmetic",_
							"differential progressive DCT arithmetic","differential spatial arithmetic")
					Pos = 0:FileSize = LenB(RequestBin)
					If ReadAsDec(RequestBin,Pos,1)=&hff then
						Do While (Pos<FileSize)
							Inc Pos,1
							Marker = ReadAsDec(RequestBin,Pos,1)
							while  Marker = &hff
								Inc Pos,1
								Marker = ReadAsDec(RequestBin,Pos,1)
							Wend
							Inc Pos,1
							Select Case Marker
								Case DHP,SOF+0,SOF+1,SOF+2,SOF+3,SOF+9,SOF+10,SOF+11,SOF+5,SOF+6,SOF+7,SOF+13,SOF+14,SOF+15:
									if marker=DHP then
										Info = "DHP"
									else
										Info = "JPG : " & arSOF(Marker-SOF)
									end if
									SOFLenght = ReadAsDec(RequestBin,Pos,2)
									Inc Pos,3 'Skip Precision
									H = ReadAsDec(RequestBin,Pos,2)
									Inc Pos,2
									W = ReadAsDec(RequestBin,Pos,2)
									Inc Pos,2
									Exit Do
								Case APP+0,APP+1,APP+2,APP+3,APP+4,APP+5,APP+6,APP+7,APP+8,APP+9,APP+10,APP+11,APP+12,APP+13,APP+14,APP+15:
									Inc Pos,ReadAsDec(RequestBin,Pos,2)
								Case DRI,SOS,DQT,DHT,DAC,DNL,EXP_:
									Inc Pos,ReadAsDec(RequestBin,Pos,2)
							End select
						Loop
					end if
				case "image/gif","gif":
					Info = ReadAsString(RequestBin,"0000",6)
					w = ReadAsEdian(RequestBin,"0006",2)
					h = ReadAsEdian(RequestBin,"0008",2)
				case "image/bmp","bmp":
					info = "Bitmap"
					w = ReadAsEdian(RequestBin,18,4)
					h = ReadAsEdian(RequestBin,22,4)
				case "image/png","png":
				Case Else
					info = "Format Not Supported "& ContentType
			end select
			arResult = array(h,w,info)
	end function



Ma non riesco a farmi restituire la Grandenzza del file...