BobotheBugbear
03-14-2006, 01:07 PM
Here is the weird part:
I am retrieving an image from the DB and I have in my image control like this:
<asp:Image ID="Image1" runat="server" Height="40px" ImageUrl='imageView.aspx?username=<%# Eval("UserName") %>' />
This then evaluates to after viewing the source to:
<img id="ctl00_bodyContent_dvThemeColors_Image1" src="imageView.aspx?username=<%#
Eval("UserName") %>" style="height:40px;border-width:0px;" />
You'll see that the username which should be there isn't as it writes it out as complete HTML. Username is valid.
What is the cause of this and how can I get it to eval correctly so that I can retrieve the image from the DB?
thanks
ps. this is in a detailsview if that matters
I am retrieving an image from the DB and I have in my image control like this:
<asp:Image ID="Image1" runat="server" Height="40px" ImageUrl='imageView.aspx?username=<%# Eval("UserName") %>' />
This then evaluates to after viewing the source to:
<img id="ctl00_bodyContent_dvThemeColors_Image1" src="imageView.aspx?username=<%#
Eval("UserName") %>" style="height:40px;border-width:0px;" />
You'll see that the username which should be there isn't as it writes it out as complete HTML. Username is valid.
What is the cause of this and how can I get it to eval correctly so that I can retrieve the image from the DB?
thanks
ps. this is in a detailsview if that matters