1、改一下你的压缩代码
Dim bs As Byte() = Convert.FromBase64String(e.PostValues(key).split(",")(1))
Dim stream As System.IO.Stream = New System.IO.MemoryStream(bs)
Dim img1 As System.Drawing.Bitmap = New System.Drawing.Bitmap(stream)
Dim slt As String ="c:\web\xp\" & e.Cookies("username") & ".jpg"
Dim bmp1 As bitmap
If img1.width > 400 Then
If 400 * (img1.height / img1.width) > 300 Then
bmp1 = new bitmap(img1, 400*(300/(400*(img1.height/img1.width))), 300)
Else
bmp1 = new bitmap(img1, 300, 300 * (img1.height / img1.width))
End If
End If
bmp1.save(slt, ImageFormat.Jpeg)
bmp1.Dispose
img1.dispose
stream.close
2、是不是返回了最顶层才退出的?如果是,看看 http://www.foxtable.com/bbs/dispbbs.asp?BoardID=2&ID=124516&skin=0