Quote:
Thanks for the pointers. I got the script to work. Is there a way to send the output of WinHttpRequest directly instead of saving the image on the hard drive and then displaying it?


Probably.

The WinHttpRequest object has a ResponseStream property which returns an IStream object.

If I remember correctly one of the things that the Response.Write method can accept is an IStream object. So calling Response.Write and passing the WinHttpRequest.ResponseStream should write out the image you grabbed.

You will also have to set the Response.ContentType to the relevant mime type for the image format.

Edit:

I was nearly right. You need to do:

dim oBody
oBody = oWinHTTP.responseBody
Response.BinaryWrite oBody

In theory you could just do:

Response.BinaryWrite oWinHTTP.responseBody

but I have had that fail in strange ways in the past


Edited by andy (12/02/2005 19:08)
_________________________
Remind me to change my signature to something more interesting someday