Advertisement
Guest User

Untitled

a guest
Feb 19th, 2019
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. protected void BtnRefresh_Click(object sender, EventArgs e)
  2. {
  3. //check object session
  4. LoginSessionData.IsValid();
  5.  
  6. //Hide the display panel
  7. DisplayMessage.Visible = false;
  8.  
  9. //add a try catch block here
  10. try
  11. {
  12.  
  13. ReportViewer1.LocalReport.Refresh();
  14. }
  15. catch (Exception ex)
  16. {
  17. m_logger.Error(ex);
  18. }
  19. }
  20.  
  21. ReportParameter p1 = new
  22. ReportParameter("ShowDescriptions", checkBox1.Checked.ToString());
  23. ReportParameter p2 = new
  24. ReportParameter("MyDate", DateTime.Now.ToString());
  25. ReportViewer1.LocalReport.SetParameters(new ReportParameter[] { p1, p2 });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement