All pastes #177627 Raw Edit

Anonymous

public text v1 · immutable
#177627 ·published 2006-09-20 15:46 UTC
rendered paste body
                 int imageLen = Upload.PostedFile.ContentLength;
		  byte[] imageByte = new byte[imageLen];
		  Upload.PostedFile.InputStream.Read(imageByte, 0, imageLen);

		   // save imageByte into the ImageBinary column
		   
		   // create a new Parameter for it 
		  Parameter imageParam = new Parameter("ImageBinaryParam", TypeCode.Byte);
		  imageParam.DefaultValue = imageByte;
		   this.dsDetail.InsertParameters.Add(imageParam);