M
Mike P
I have a piece of code in VB that I want to use to resize images. I
think I have successfully converted most of it to C#, but I am not sure
about this bit :
Function ThumbnailCallback() as Boolean
Return False
End Function
Here is the bit of the code that is calling it :
Response.ContentType = "image/gif"
If imageHeight > 0 and imageWidth > 0 then
Dim dummyCallBack as System.Drawing.Image.GetThumbNailImageAbort
dummyCallBack = New _
System.Drawing.Image.GetThumbnailImageAbort(AddressOf
ThumbnailCallback)
Dim thumbNailImg as System.Drawing.Image
thumbNailImg = fullSizeImg.GetThumbnailImage(imageWidth,
imageHeight, _
dummyCallBack,
IntPtr.Zero)
thumbNailImg.Save(Response.OutputStream, ImageFormat.Gif)
Can anybody help?
think I have successfully converted most of it to C#, but I am not sure
about this bit :
Function ThumbnailCallback() as Boolean
Return False
End Function
Here is the bit of the code that is calling it :
Response.ContentType = "image/gif"
If imageHeight > 0 and imageWidth > 0 then
Dim dummyCallBack as System.Drawing.Image.GetThumbNailImageAbort
dummyCallBack = New _
System.Drawing.Image.GetThumbnailImageAbort(AddressOf
ThumbnailCallback)
Dim thumbNailImg as System.Drawing.Image
thumbNailImg = fullSizeImg.GetThumbnailImage(imageWidth,
imageHeight, _
dummyCallBack,
IntPtr.Zero)
thumbNailImg.Save(Response.OutputStream, ImageFormat.Gif)
Can anybody help?