protected void btnAddClaim_Click(object sender, EventArgs e) { string pkCode = ""; Session["View"] = false; string cpoint = Session["UserCpoint"].ToString(); if (cpoint.Length < 3) { cpoint = "10" + cpoint; } while (pkCode == "") { pkCode = function.GeneratorPK(int.Parse(cpoint)); } if (pkCode != "") { Session["CodePK"] = pkCode; Response.Redirect("/Claim/claimDetailForm"); } }