I am trying to send report from sql reportserver 2008 as e mail attachment using ASP.NET and C#, Till now I learned how to Get report as PDF in my code , Now I wanna combine line of codes like
byte[] bytes = rview.ServerReport.Render(format, deviceInfo, out mimeType, out encoding, out extension, out streamids, out warnings);
Response.OutputStream.Write(bytes, 0, bytes.Length);
Attachment reportAttachment = new Attachment(Response.OutputStream.Write(bytes,0,bytes.Length),"ado"); //Here I go wrong
Thanx in advance