CotteIrogue
New Member
I have created a Crystal Report. It is working fine. Then I tried to use it in Asp.Net using \[code\]<CR:CrystalReportViewer ID="CrystalReportViewer1" runat="server"DisplayGroupTree="False" /> \[/code\]The first time, it works fine but when I click on the \[code\]print\[/code\] button, the report disappears and gives an error. When I move my \[code\]BindReport\[/code\] method out of \[code\]if(!IsPostBack)\[/code\] then it starts working fine.Below gives error when print button is clicked:\[code\]protected void Page_Load(object sender, EventArgs e){ if(!IsPostBack) { BindReport(); }}\[/code\]But this works fine\[code\]protected void Page_Load(object sender, EventArgs e){ BindReport(); }\[/code\]Can someone help me understand what is the reason?