Reylin Mathew

Reylin Mathew

  • NA
  • 347
  • 74.9k

Image Upload in Byte

May 17 2018 12:03 PM
I have a datatable containg image that is saved as byte,
I dont want to save image into a folder only saved to datatable.
then I want to check the size of the image not exceed to 500 mb.
WHEN i use this code, i got object reference not set to an instance ..
 
if (fupImage.HasFile != null)
{
string stdid = Session["StdId"].ToString();
int length =fupImage.PostedFile.ContentLength;
if (length > 500 * 1024)
{
Response.Write("Ur image is too large");
}
}
 
I have to upload image when image column of datatable become null value too..
 
 
How can I RESOLVE it ..pls help...Thanks in ADVANCE..:) 

Answers (1)