コード例 #1
0
        protected void btnPesinKaydet_Click(object sender, EventArgs e)
        {
            if (Session["idp"] != null)
            {
                int    id    = Int32.Parse(Session["idp"].ToString());
                string unvan = txtUnvan.Text;
                string vd    = txtVD.Text;
                string tc    = txtVN.Text;
                Pesin  p     = new Pesin();
                p.id    = id;
                p.unvan = unvan;
                p.vd    = vd;
                p.tc    = tc;
                p.adres = txtAdres.Text;

                Session["pesin"] = p;
                Session["idp"]   = null;

                System.Text.StringBuilder sb = new System.Text.StringBuilder();
                sb.Append(@"<script type='text/javascript'>");
                sb.Append("$('#addModal').modal('hide');");
                sb.Append("$('#detailModal').modal('show');");
                sb.Append(@"</script>");
                ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "AddShowModalScript", sb.ToString(), false); string tip = Request.QueryString["tip"];
            }
        }
コード例 #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!User.Identity.IsAuthenticated)
            {
                System.Web.HttpContext.Current.Response.Redirect("/Account/Giris.aspx");
            }

            if (Session["idint"] != null)
            {
                int id = Int32.Parse(Session["idint"].ToString());
                yazdirmaInternet(id);
            }
            else if (Session["ids"] != null)
            {
                int id = Int32.Parse(Session["ids"].ToString());
                yazdirmaServis(id);
            }
            else if (Session["pesin"] != null)
            {
                Pesin p = (Pesin)Session["pesin"];
                yazdirmaPesin(p.id, p.unvan, p.tc, p.vd, p.adres);
            }

            using (radiusEntities dc = MyContext.Context(firma))
            {
                HepsiniGoster(dc);
            }
        }