My form can do a file upload but can't do a file download (from a sql image column)

Hi everyone,

I've created an ASP.NET C# form that displays a record from a SQL database on the web. I can get everything to load fine except for a file stored in an "image" (datatype) field.
What I want is the page to display either a picture or a link or something that the user can click to download the file.
I can't seem to figure out is:
1. what type of object to put in the form (text link, image, etc.) to allow for a downloadable file.
2. how to assign the file contained in the image column to some sort of variable. For the other columns in the sql table I'm using:
Variable.Text = (string)dtrLinkField["SQLFIELD"];
but this doesn't work for the file stored in the sql image column.
3. How to assign the variable (in 2 above) to the form object (in 1 above) so that the user clicks (or Right-clicks/save target as) and can download the file.
Any help is greatly appreciated,
2/9/2005 9:06:07 PM 93655 articles. 6 followers. Follow

0 Replies

Similar Articles

[PageSpeed] 19
Get it on Google Play
Get it on Apple App Store