Olav
You need a url that returns the image you want, which you bind to each listitem in your datagrid/datalist, e.g. <img src='<%# "GetImage.aspx?src=" + ID %>'
In this example, GetImage.aspx uses the ID you pass and does the i/o to get a byte array from the blob, then returns it in the output stream as a picture, e.g
response.ContentType = "image/jpeg"
response.BinaryWrite(MyByteArray
The other nice thing about using GetImage is that you can very simply modify the image before you return it to the stream, such as add a description or copyright notice onto the picture, return a thumbnail, etc. In that case, you'd create your bitmap from the blob, modify it however, then do bitmap.Save(Response.OutputStream, Imaging.ImageFormat.Jpeg) to output it to the stream
For a great discussion of this and a lot more, check out Esposito's Programming Microsoft ASP.NET from MS Press (pp. 1036-1044)
hth
Bil
----- Olav Tollefsen wrote: ----
How can I display photo images stored in a SQL Server 2000 databases in
DataList or DataGrid without having to write the images to files first
Ola