>  AspTear
>  CodeLook
>  PortalPage Filter



>  FAQ
>  Documentation
>  Ask Us!


Free Tools

>  Free Components
>  Free Sourcecode
>  IIS Development
>  SharpDevelop



>  Webprogrammierung
>  Schulungen
>  Datenbanken
>  Netzwerk



>  Über uns
>  Referenzen
>  Kontaktinformationen
>  Anfrageformular

Home | Products | Support Central | Buy! | About Us  

FAQ: Why can't I retrieve images and send them to the client?

For example, you have the following code:

strImage = ""
MyImage = xobj.Retrieve(strImage, Request_GET, "", "", "")
Response.ContentType = "Image/gif"
Response.BinaryWrite MyImage

Though it looks perfectly legal, the problem is that Retrieve works with textual data only, and converts binary data to textual representation. Hence when you pass the retrieved image on to the client, it is no longer an image and can't be displayed.

The next release will have a function BinaryRetrieve to work around this limitation.

How can you implement the requirement today (1.5)? You can use Save to retrieve the image to a file and then redirect to the file. Instead of redirecting, you could also use SoftArtisans FileManger to do a binary read of the file and then use Response.BinaryWrite.

© 1999-2018 AlphaSierraPapa. All Rights Reserved.
Back to the top.