Posted on: 9/11/2013 11:05:43 AM | Views : 776

Hi,
Am having a invoice.aspx page in that i will view a crystal report after checking all the values ....admin click a button that same crystal report need to be mailed for a particular mail id...i typed below code but it is showing an error....Missing Parameter when the bold line is executed....
protected void Button1_Click(object sender, EventArgs e) { ReportDocument crystalReport = new ReportDocument(); crystalReport.Load(Server.MapPath("~/Copy of CrystalReport.rpt")); DataSet dsrep = new DataSet(); GetData(dsrep); crystalReport.SetDataSource(dsrep); using (MailMessage mm = new MailMessage("sender87@gmail.com", "receiver6@gmail.com")) { mm.Subject = "Invoice"; mm.Body = "Invoice"; System.Net.Mail.Attachment attachment; attachment = new System.Net.Mail.Attachment(crystalReport.ExportToStream(ExportFormatType.PortableDocFormat), ...

Go to the complete details ...