TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
azizul azmi
NA
180
850
how to read binary data from database more than 32kb
Jun 23 2014 9:19 PM
hello anybody can help me..to solve my problem...i m only read binary data (less than 32kb) from database ...can read more than 32kb?
thanks a lot :)
this my code :
using (AseConnection conn = new AseConnection(conngais.constring.Connection()))
{
conn.Open();
using (AseCommand cmd = conn.CreateCommand())
{
cmd.CommandText = "select f8446atifek from t8446x where f8446id_publish=@id";
cmd.Parameters.Add("@id", AseDbType.Integer).Value = Convert.ToInt64(id);
using (AseDataReader reader = cmd.ExecuteReader(CommandBehavior.SequentialAccess))
{
if (reader.Read())
{
//reader.GetBytes(0, 0, (byte[])reader.GetValue(0), 0, 500);
//.GetBytes(0, startIndex, outbyte, 0, buffersize);
Byte[] pdfData = (byte[])reader.GetValue(0);
Response.Buffer = true;
Response.ContentType = "application/pdf";
Response.AddHeader("content-disposition","attachment;filename=Tr.pdf");
Response.BinaryWrite(pdfData);
Response.End();
}
}
}
}
Reply
Answers (
0
)
IQueryable returns 3693 items but inserts 1000 to dropdown
Crystal Report 11 with C #