Hello!
I have a code in Asp.net that calls a method in the code behind:
<
The objective of the following code is to check if an image exists in the databse. I have created a method in the code behind(c#) that would check the image field in the database (ImageURL), if it is there, then the method should tell the ASP.net code to place the image in the browser. However, if it is not there, then the image is ignored. I just don't know how to tell the asp.net from c# to execute the code. I'm using a boolean, and I'm not sure if this is correct.
C# Code:
{
objConn.Open();
OleDbDataReader objRdr = objCmd.ExecuteReader();
//For example <Img src="<%# DataBind.Eval(Container.DataItem, "ImageURL") %>
//meaning, go to the asp code and get the image to place it in the browser
}
else
//meaning, don't get the image
I would greatly appreciate some help.
Thanks,
Eduardo