image DBNull
-
SqlDataReader read = cmd.ExecuteReader(); read.Read(); photo.Visible = false; if (read["newsPhoto"] != DBNull.Value) { photo.Visible = true; photo.ImageUrl = "retriveImage.aspx?id=" + read["newId"].ToString(); } this my code to display image but all time enter this if statment either i upload the image or not all time he enter if statment ... where the problem ?????
Palestine
-
SqlDataReader read = cmd.ExecuteReader(); read.Read(); photo.Visible = false; if (read["newsPhoto"] != DBNull.Value) { photo.Visible = true; photo.ImageUrl = "retriveImage.aspx?id=" + read["newId"].ToString(); } this my code to display image but all time enter this if statment either i upload the image or not all time he enter if statment ... where the problem ?????
Palestine
does the path come through from the DB ? Does it exist ?
Christian Graus - Microsoft MVP - C++ "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )