protected void btnReport_Click(object sender, EventArgs e) { Account aAccount = (Account)ViewState["Account"]; if (aAccount == null) { lblReport.InnerText = "There is no data!"; return; } lblReport.InnerText = aAccount.ShowReport(); }